remfin: fix tra_to_tba

This fixes a complementation bug reported by Juraj Major and Tereza
Šťastná.

* spot/twaalgos/remfin.cc (is_scc_tba_type): Fix the condition for
handling Fin-alone pairs.
* tests/core/complement.test: Add Juraj & Tereza's test case.
* NEWS: Mention it.
This commit is contained in:
Alexandre Duret-Lutz 2019-12-05 22:27:19 +01:00
parent e778965730
commit c36b1588fc
3 changed files with 28 additions and 2 deletions

View file

@ -142,3 +142,19 @@ State: 1
--END--
EOF
diff out expected
# The following automaton used to be badly complemented due
# to a bug in the Rabin-to-BA conversion.
# Reported by Juraj Major and Tereza Šťastná.
cat >pos.hoa <<EOF
HOA: v1 States: 8 Start: 0 AP: 3 "a" "b" "c" Acceptance: 3 Fin(0) |
(Inf(1) & Fin(2)) properties: trans-labels explicit-labels trans-acc
--BODY-- State: 0 [0&1&2] 5 {2} State: 1 [0&1&!2] 1 {0} [0&1&2]
2 [0&!1&!2] 6 State: 2 [!0&1&2] 4 State: 3 [!0&1&2] 2 {0} [0&1&2] 3
[0&1&2] 1 State: 4 [!0&!1&!2] 7 {2} State: 5 [!0&1&!2] 3 [!0&!1&2]
5 [!0&!1&!2] 2 {0} State: 6 [!0&1&2] 7 {0 1 2} [!0&!1&!2] 6 State: 7
[!0&1&2] 4 [0&!1&2] 7 --END--
EOF
autfilt --complement pos.hoa >neg.hoa
autfilt -q --intersect=pos.hoa neg.hoa && exit 1
: