You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(b909): Fix false positive affecting containers of mutables (#469)
* fix(b909): Fix false positive affecting containers of mutables
The false positives occurred when trying to edit a dictionary while
iterating over a list of dictionaries:
```
lst: list[dict] = [{}, {}, {}]
for dic in lst:
dic["key"] = False # was false positive - fixed now
```
* fix(b909): Allow mutation of dict[key] form
These changes allow the following:
```
some_dict = {"foo": "bar"}
for key in some_dict:
some_dict[key] = 3 # no error (previously error'd)
```
* fix(b909): Fix python 3.8 incompatibility
Turns out, that the slice type was changed in python 3.9.
> Changed in version 3.9: Simple indices are represented by their value,
> extended slices are represented as tuples.
from https://docs.python.org/3/library/ast.html#module-ast
0 commit comments