mirror of
https://github.com/m-labs/artiq.git
synced 2024-12-24 19:04:02 +08:00
transform/inline: fix subscript handling
This commit is contained in:
parent
8aa69cb959
commit
0ad2b4d09b
@ -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)
|
||||
|
Loading…
Reference in New Issue
Block a user