forked from VimPlug/jedi
decorators should also be included in the static analysis
This commit is contained in:
@@ -138,4 +138,11 @@ def get_module_statements(module):
|
||||
imports |= set(scope.imports)
|
||||
stmts |= add_stmts(scope.statements)
|
||||
stmts |= add_stmts(r for r in scope.returns if r is not None)
|
||||
|
||||
try:
|
||||
decorators = scope.decorators
|
||||
except AttributeError:
|
||||
pass
|
||||
else:
|
||||
stmts |= add_stmts(decorators)
|
||||
return stmts, imports
|
||||
|
||||
Reference in New Issue
Block a user