summaryrefslogtreecommitdiffstats
path: root/Tools/clinic
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2017-03-30 15:29:23 (GMT)
committerGitHub <noreply@github.com>2017-03-30 15:29:23 (GMT)
commitd4edfc9abffca965e76ebc5957a92031a4d6c4d4 (patch)
treed985a5ba3c7dd8ec3183014962d650724f61ece9 /Tools/clinic
parent762ec97ea68a1126b8855996c61fa8239dc9fff7 (diff)
downloadcpython-d4edfc9abffca965e76ebc5957a92031a4d6c4d4.zip
cpython-d4edfc9abffca965e76ebc5957a92031a4d6c4d4.tar.gz
cpython-d4edfc9abffca965e76ebc5957a92031a4d6c4d4.tar.bz2
bpo-29935: Fixed error messages in the index() method of tuple, list and deque (#887)
when pass indices of wrong type.
Diffstat (limited to 'Tools/clinic')
-rwxr-xr-xTools/clinic/clinic.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Tools/clinic/clinic.py b/Tools/clinic/clinic.py
index 1d570f1..6be0ab2 100755
--- a/Tools/clinic/clinic.py
+++ b/Tools/clinic/clinic.py
@@ -2670,9 +2670,9 @@ class slice_index_converter(CConverter):
def converter_init(self, *, accept={int, NoneType}):
if accept == {int}:
- self.converter = '_PyEval_SliceIndex'
+ self.converter = '_PyEval_SliceIndexNotNone'
elif accept == {int, NoneType}:
- self.converter = '_PyEval_SliceIndexOrNone'
+ self.converter = '_PyEval_SliceIndex'
else:
fail("slice_index_converter: illegal 'accept' argument " + repr(accept))