Commit d22ecba9 authored by Alexandre Duret-Lutz's avatar Alexandre Duret-Lutz

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.
parent d0b38156
......@@ -2,7 +2,7 @@ New in spot 1.99.6a (not yet released)
Command-line tools:
* BACKWARD INCOMPATIBILE CHANGE: All tools that output automata now
* BACKWARD INCOMPATIBLE CHANGE: All tools that output automata now
use the HOA format by default instead of the GraphViz output.
This makes it easier to pipe several commands.
......@@ -41,6 +41,10 @@ New in spot 1.99.6a (not yet released)
renamed to spot/ltsmin/, so that installed and non-installed
directories can be used similarly.
* twa::~twa() is now calling
get_dict()->unregister_all_my_variable(this);
so this does not need to be done in any subclass.
* is_inherently_weak_automaton() is a new function, and
check_strength() has been modified to also check inherently weak
automata.
......
......@@ -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
......
......@@ -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;
......
......@@ -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_)
......
......@@ -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);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment