fixed edge cases of dynamic array completion, which led to StopIteration
This commit is contained in:
1 parent
8059b075c6
commit
b204f2f5d9
2 files changed
+4
-1
No files matched your search
+2
-1
@@ -239,8 +239,9 @@ def _check_array_additions(compare_array, module, is_list):
|
||||
for c in calls:
|
||||
call_path = list(c.generate_call_path())
|
||||
separate_index = call_path.index(add_name)
|
||||
if not len(call_path) > separate_index + 1:
|
||||
if add_name == call_path[-1] or separate_index == 0:
|
||||
# this means that there is no execution -> [].append
|
||||
# or the keyword is at the start -> append()
|
||||
continue
|
||||
backtrack_path = iter(call_path[:separate_index])
|
||||
|
||||
|
||||
Reference in new issue
Block a user