wdba: adjust to work on any TωA

* src/twaalgos/minimize.cc, src/twaalgos/safety.cc,
src/twaalgos/safety.hh: Adjust.
* src/tests/wdba2.test: More tests.
This commit is contained in:
Alexandre Duret-Lutz 2015-05-14 17:25:36 +02:00
parent 8080813303
commit dd87bdf868
4 changed files with 54 additions and 18 deletions

View file

@ -493,10 +493,6 @@ namespace spot
twa_graph_ptr minimize_wdba(const const_twa_graph_ptr& a)
{
if (a->acc().uses_fin_acceptance())
throw std::runtime_error
("minimize_wdba cannot work with Fin acceptance");
hash_set* final = new hash_set;
hash_set* non_final = new hash_set;
@ -518,6 +514,7 @@ namespace spot
// (i.e., it is not the start of any accepting word).
scc_info sm(det_a);
sm.determine_unknown_acceptance();
unsigned scc_count = sm.scc_count();
// SCC that have been marked as useless.
std::vector<bool> useless(scc_count);