remfin: simplify tra_to_tba using generic emptiness check

* spot/twaalgos/remfin.cc (tra_to_tba): Remove the SCC-emptiness
check that was done by creating a temporary automaton.  Use the
scc_info::check_scc_emptiness() function instead.
* spot/twaalgos/sccinfo.cc,
spot/twaalgos/sccinfo.hh (scc_info::check_scc_emptiness): Mark
this function as const.
(scc_and_mark_filter): Make sure we only combine with a lower filter
of the same type.
* spot/twaalgos/genem.cc: Remove one stray debugging statement.
* tests/python/genem.py: Remove a duplicate test.
This commit is contained in:
Alexandre Duret-Lutz 2019-12-05 22:49:42 +01:00
parent 66bd5db0af
commit 935c412df0
5 changed files with 54 additions and 92 deletions

View file

@ -75,8 +75,6 @@ namespace spot
else
{
int fo = acc.fin_one();
if (fo < 0)
std::cerr << autacc << acc << '\n';
assert(fo >= 0);
// Try to accept when Fin(fo) == true
acc_cond::mark_t fo_m = {(unsigned) fo};
@ -162,6 +160,8 @@ namespace spot
bool generic_emptiness_check_for_scc(const scc_info& si,
unsigned scc)
{
if (si.is_accepting_scc(scc))
return false;
return is_scc_empty(si, scc, si.get_aut()->acc(), nullptr);
}