1
0
forked from VimPlug/jedi

fix returns/flow command edge cases

This commit is contained in:
Dave Halter
2014-05-16 12:33:00 +02:00
parent d59e21f43c
commit 8e27ed556e
+2
View File
@@ -114,6 +114,7 @@ def get_module_statements(module):
new = set() new = set()
for stmt in stmts: for stmt in stmts:
if isinstance(stmt, pr.Scope): if isinstance(stmt, pr.Scope):
new |= add_stmts(stmt.inputs)
continue continue
if isinstance(stmt, pr.KeywordStatement): if isinstance(stmt, pr.KeywordStatement):
stmt = stmt.stmt stmt = stmt.stmt
@@ -136,4 +137,5 @@ def get_module_statements(module):
for scope in module.walk(): for scope in module.walk():
imports |= set(scope.imports) imports |= set(scope.imports)
stmts |= add_stmts(scope.statements) stmts |= add_stmts(scope.statements)
stmts |= add_stmts(scope.returns)
return stmts, imports return stmts, imports