Fix an issue where a slice is indexed, fixes #1748

This commit is contained in:
Dave Halter
2021-11-17 00:14:59 +01:00
parent a17b958078
commit 8bc9c8cda2
2 changed files with 28 additions and 10 deletions

View File

@@ -44,6 +44,8 @@ b[int():]
#? list()
b[:]
#? int()
b[:, :-1]
#? 3
b[:]
@@ -67,6 +69,20 @@ class _StrangeSlice():
#? slice()
_StrangeSlice()[1:2]
for x in b[:]:
#? int()
x
for x in b[:, :-1]:
#?
x
class Foo:
def __getitem__(self, item):
return item
#?
Foo()[:, :-1][0]
# -----------------
# iterable multiplication