-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(🐞) FURB118
(reimplemented-operator) false positive when reference in the item position
#10898
Comments
FURB118
(reimplemented-operator) false positiveFURB118
(reimplemented-operator) false positive when reference in the item position
Yeah, that's certainly not safe. We should either mark the fix as unsafe or "properly" fix (although that would likely require to replace all call-sites of |
Or detect if there is a reference in the item then don't try to fix it? |
shouldn't it just not even report the error at all in that case, since it means there's no way to properly convert it to an |
Could be a constant |
playground
but if we follow that direction:
Original issue:
playground
This function references an input in the value position, making it impossible to rewrite as an attribute
And if we define it in the
__init__
then it would always use the intial value offoo
:The text was updated successfully, but these errors were encountered: