diff options
Diffstat (limited to 'debug/DebugInformation.ml')
-rw-r--r-- | debug/DebugInformation.ml | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/debug/DebugInformation.ml b/debug/DebugInformation.ml index ed00ea0d..be322a55 100644 --- a/debug/DebugInformation.ml +++ b/debug/DebugInformation.ml @@ -295,6 +295,16 @@ let gen_comp_typ sou id at = let remove_unused id = try let id' = Hashtbl.find stamp_to_definition id.stamp in + let var = Hashtbl.find definitions id' in + match var with + | Function _ -> () + | _ -> Hashtbl.remove definitions id'; + Hashtbl.remove stamp_to_definition id.stamp + with Not_found -> () + +let remove_unused_function id = + try + let id' = Hashtbl.find stamp_to_definition id.stamp in Hashtbl.remove definitions id'; Hashtbl.remove stamp_to_definition id.stamp with Not_found -> () |