In a list comprehension, if the target variable appears in the main expression followed by an attribute access, the target variable is not recognized. Example: [foo.bar() for foo in somelist] The first 'foo' is underlined in yellow. This happens even if the attribute expression doesn't apply to this variable. For example: [foo.bar(item) for item in lst] # this works [foo(item).bar for item in lst] # this doesn't work
Git commit 21aa5ca9d6cd4ddb3e2431fa5b2e526a8f5239e2 by Sven Brauch. Committed on 16/03/2012 at 20:52. Pushed by brauch into branch 'master'. Fix a bug with generator ranges The implementation of this really, really sucks... but I don't know of a better one. :( M +11 -4 duchain/contextbuilder.cpp M +1 -0 duchain/tests/pyduchaintest.cpp http://commits.kde.org/kdev-python/21aa5ca9d6cd4ddb3e2431fa5b2e526a8f5239e2