Globals appearing in vectors or rotations inside a list still caused a crash. Fixes #3 again.
This commit is contained in:
@@ -226,6 +226,14 @@ class deadcode(object):
|
||||
sym = self.symtab[0][subnode['name']]
|
||||
sym['W'] = False
|
||||
self.tree[sym['Loc']]['X'] = True
|
||||
elif subnode['nt'] in ('VECTOR', 'ROTATION'):
|
||||
for sub2node in subnode['ch']:
|
||||
# can only happen in globals
|
||||
if sub2node['nt'] == 'IDENT':
|
||||
assert sub2node['scope'] == 0
|
||||
sym = self.symtab[0][sub2node['name']]
|
||||
sym['W'] = False
|
||||
self.tree[sym['Loc']]['X'] = True
|
||||
else:
|
||||
self.MarkReferences(child[0])
|
||||
return True
|
||||
|
||||
Reference in New Issue
Block a user