Skip to content

Understand augmented assignments #192

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

Open
pylint-bot opened this issue Sep 24, 2015 · 0 comments
Open

Understand augmented assignments #192

pylint-bot opened this issue Sep 24, 2015 · 0 comments
Labels
Enhancement ✨ Improvement to a component

Comments

@pylint-bot
Copy link

Originally reported by: Claudiu Popa (BitBucket: PCManticore, GitHub: @PCManticore)


Closely related to #115.

We should try to understand the various forms of augmented assignments. The simplest case, for instance, causes false positives with numpy.core (which is fixed in astroid through a transform, not the proper fix though)

#!python

a = [...]
a += [...]
a += [...]
a # infer with all mutations

Since I gave numpy.core as an example, the all attribute is computed by adding the all values of subimports into this attribute through augmented assignment.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement ✨ Improvement to a component
Projects
None yet
Development

No branches or pull requests

1 participant