stength: fix detection of terminal automata

Fixes issue #553.

* spot/twaalgos/strength.cc (is_type_automaton): Make sure an
accepting SCC is not followed by a rejecting one.
(is_terminal_automaton): Mark the third-argument version deprecated.
* spot/twaalgos/strength.hh: Adjust.
* spot/twaalgos/couvreurnew.cc: Remove the inappropriate terminal
optimization.
* bin/ltlfilt.cc, spot/tl/hierarchy.cc, spot/twaalgos/gfguarantee.cc,
tests/core/ikwiad.cc: Remove usage of the third argument of
is_terminal_automaton.
* tests/core/readsave.test, tests/core/strength.test: Adjust test
cases.
* NEWS: Mention the bug.
This commit is contained in:
Alexandre Duret-Lutz 2023-11-21 16:40:33 +01:00
parent 63362d535f
commit 62fb0c354e
10 changed files with 75 additions and 82 deletions

View file

@ -1368,8 +1368,7 @@ checked_main(int argc, char** argv)
}
else
{
bool g = is_terminal_automaton(ensure_digraph(a),
nullptr, true);
bool g = is_terminal_automaton(ensure_digraph(a));
bool s = is_safety_automaton(ensure_digraph(a));
if (g && !s)
{

View file

@ -826,7 +826,7 @@ test `autfilt --is-terminal -c output4` = 0
sed 's/\[0\]/[t]/g' expect4 > output4d
test `autfilt -B --small output4d | autfilt --is-terminal -c` = 1
test `autfilt --is-terminal -c output4d` = 0 # FIXME: Issue #553
test `autfilt --is-terminal -c output4d` = 1 # Issue #553
autfilt -B -Hv --small input4 >output5
cat >expect5<<EOF

View file

@ -679,7 +679,7 @@ AP: 1 "a"
acc-name: Buchi
Acceptance: 1 Inf(0)
properties: trans-labels explicit-labels trans-acc complete
properties: deterministic very-weak
properties: deterministic terminal very-weak
--BODY--
State: 0
[t] 0