From 2b3f00cbc1abbb6c7ae6a30c1856a28ad79f999f Mon Sep 17 00:00:00 2001 From: Lars-Peter Clausen Date: Tue, 31 Jan 2012 21:39:53 +0100 Subject: [PATCH] fhdl/namer: Add support for STORE_DEREF opcode Signed-off-by: Lars-Peter Clausen --- migen/fhdl/namer.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/migen/fhdl/namer.py b/migen/fhdl/namer.py index 530eedcc1..070d4ba7e 100644 --- a/migen/fhdl/namer.py +++ b/migen/fhdl/namer.py @@ -16,6 +16,9 @@ def get_var_name(frame): elif opc == "STORE_FAST": name_index = int(code.co_code[index+1]) return code.co_varnames[name_index] + elif opc == "STORE_DEREF": + name_index = int(code.co_code[index+1]) + return code.co_cellvars[name_index] elif opc == "LOAD_GLOBAL" or opc == "LOAD_ATTR" or opc == "LOAD_FAST": index += 3 elif opc == "DUP_TOP":