twa: call unregister_all_my_variables()

Fixes #129.

* spot/twa/twa.cc (~twa): call unregister_all_my_variables()
* spot/twa/twagraph.hh, spot/twa/twaproduct.cc,
spot/twaalgos/stutter.cc: Simplify.
* NEWS: Mention the change.
This commit is contained in:
Alexandre Duret-Lutz 2016-01-10 21:02:31 +01:00
parent d0b38156f3
commit d22ecba9b6
5 changed files with 6 additions and 8 deletions

View file

@ -43,6 +43,7 @@ namespace spot
last_support_conditions_input_->destroy();
delete iter_cache_;
release_named_properties();
get_dict()->unregister_all_my_variables(this);
}
bdd

View file

@ -202,7 +202,6 @@ namespace spot
virtual ~twa_graph()
{
get_dict()->unregister_all_my_variables(this);
// Prevent this state from being destroyed by ~twa(),
// as the state will be destroyed when g_ is destroyed.
last_support_conditions_input_ = nullptr;

View file

@ -315,7 +315,6 @@ namespace spot
twa_product::~twa_product()
{
get_dict()->unregister_all_my_variables(this);
// Prevent these states from being destroyed by ~tgba(): they
// will be destroyed before when the pool is destructed.
if (last_support_conditions_input_)

View file

@ -215,11 +215,6 @@ namespace spot
acc_.set_generalized_buchi();
}
virtual ~tgbasl()
{
get_dict()->unregister_all_my_variables(this);
}
virtual const state* get_init_state() const override
{
return new state_tgbasl(a_->get_init_state(), bddfalse);