diff options
Diffstat (limited to 'passes/opt/opt_share.cc')
-rw-r--r-- | passes/opt/opt_share.cc | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/passes/opt/opt_share.cc b/passes/opt/opt_share.cc index 819a0e460..e3e9511fd 100644 --- a/passes/opt/opt_share.cc +++ b/passes/opt/opt_share.cc @@ -271,10 +271,9 @@ struct OptShareWorker } } log(" Removing %s cell `%s' from module `%s'.\n", cell->type.c_str(), cell->name.c_str(), module->name.c_str()); - module->cells.erase(cell->name); + module->remove(cell); OPT_DID_SOMETHING = true; total_count++; - delete cell; } else { sharemap[cell] = cell; } |