From: Eddie Hung Date: Tue, 14 Apr 2020 16:31:06 +0000 (-0700) Subject: kernel: Design::remove(RTLIL::Module *) to check refcount_modules_ X-Git-Tag: working-ls180~632^2~1 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=635b2b8939f32a3551114332147a8323217f4474;p=yosys.git kernel: Design::remove(RTLIL::Module *) to check refcount_modules_ --- diff --git a/kernel/rtlil.cc b/kernel/rtlil.cc index d9003f28c..3e27fdecd 100644 --- a/kernel/rtlil.cc +++ b/kernel/rtlil.cc @@ -597,6 +597,7 @@ void RTLIL::Design::remove(RTLIL::Module *module) } log_assert(modules_.at(module->name) == module); + log_assert(refcount_modules_ == 0); modules_.erase(module->name); delete module; }