forked from M-Labs/artiq
1
0
Fork 0

transform/inline: fix subscript handling

This commit is contained in:
Sebastien Bourdeauducq 2014-09-09 21:03:15 +08:00
parent 8aa69cb959
commit 0ad2b4d09b
1 changed files with 1 additions and 2 deletions

View File

@ -96,7 +96,7 @@ class _ReferenceManager:
evd.update(inspect.getmodule(obj).__dict__)
return eval_ast(ref, evd)
else:
raise KeyError
raise KeyError(ast.dump(ref))
def set(self, obj, funcname, name, value):
self.to_inlined[(id(obj), funcname, name)] = value
@ -147,7 +147,6 @@ class _ReferenceReplacer(ast.NodeTransformer):
visit_Name = visit_ref
visit_Attribute = visit_ref
visit_Subscript = visit_ref
def visit_Call(self, node):
func = self.rm.get(self.obj, self.funcname, node.func)