From 658bfe6c92b6dccea353da38a7651c61cd4ef1ce Mon Sep 17 00:00:00 2001 From: Peter Wu Date: Sat, 3 Dec 2011 12:02:01 +0000 Subject: Support global static variables --- pp2cc.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'pp2cc.py') diff --git a/pp2cc.py b/pp2cc.py index 8f6a581..03a57a1 100755 --- a/pp2cc.py +++ b/pp2cc.py @@ -1000,7 +1000,8 @@ class Parse(object): size += 1 try: - linked_node.variables.declName(name, size) + is_static = "static" in linked_node.node.storage + linked_node.variables.declName(name, size, is_static=is_static) # address of variable split up in register and displacement var_reg, var_disp = linked_node.variables.getAddress(name) except RuntimeError as errmsg: -- cgit v1.2.1