Remove the symbol table entry too when removing a global state/function/var.
This commit is contained in:
@@ -489,6 +489,9 @@ class deadcode(object):
|
||||
delete = self.SymbolReplacedOrDeleted(node)
|
||||
|
||||
if delete:
|
||||
if node['nt'] in ('DECL', 'STDEF', 'FNDEF'):
|
||||
# Delete the symbol table entry too
|
||||
del self.symtab[0][node['name']]
|
||||
del self.tree[idx]
|
||||
del LocMap[idx]
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user