twa_graph: add support for universal initial states
The only missing point is that the HOA parser cannot deal with multiple universal initial states, as seen in parseaut.test. * spot/graph/graph.hh (new_univ_dests): New function, extracted from... (new_univ_edge): ... this one. * spot/twa/twagraph.hh (set_univ_init_state): Implement using new_univ_dests. * spot/twaalgos/dot.cc, spot/twaalgos/hoa.cc, python/spot/impl.i: Add support for universal initial states. * spot/parseaut/parseaut.yy: Add preliminary support for universal initial states. Multiple universal initial states are still not supported. * tests/core/alternating.test, tests/core/parseaut.test, tests/python/alternating.py: Adjust tests and exercise this new feature.
This commit is contained in:
parent
d5c9c34514
commit
48c812a595
9 changed files with 193 additions and 88 deletions
|
|
@ -24,7 +24,7 @@ set -e
|
|||
cat >alt.hoa <<EOF
|
||||
HOA: v1.1
|
||||
States: 7
|
||||
Start: 0
|
||||
Start: 0&2
|
||||
acc-name: co-Buchi
|
||||
Acceptance: 1 Fin(0)
|
||||
AP: 2 "b" "a"
|
||||
|
|
@ -62,14 +62,17 @@ digraph G {
|
|||
label="Fin(⓿)"
|
||||
labelloc="t"
|
||||
I [label="", style=invis, width=0]
|
||||
I -> 0
|
||||
I -> -11 [dir=none]
|
||||
-11 [label=<>,width=0,height=0,shape=none]
|
||||
-11 -> 0
|
||||
-11 -> 2
|
||||
0 [label="((((a) U (b)) && GF(b)) && FG(a))"]
|
||||
0 -> -1 [label="b", dir=none]
|
||||
-1[label=<>,width=0,height=0,shape=none]
|
||||
-1 [label=<>,width=0,height=0,shape=none]
|
||||
-1 -> 3
|
||||
-1 -> 1
|
||||
0 -> -4 [label="a & !b", style=bold, color="#F15854", dir=none]
|
||||
-4[label=<>,width=0,height=0,shape=none]
|
||||
-4 [label=<>,width=0,height=0,shape=none]
|
||||
-4 -> 5 [style=bold, color="#F15854"]
|
||||
-4 -> 3 [style=bold, color="#F15854"]
|
||||
-4 -> 1 [style=bold, color="#F15854"]
|
||||
|
|
@ -81,7 +84,7 @@ digraph G {
|
|||
3 [label="GF(b)"]
|
||||
3 -> 3 [label="b"]
|
||||
3 -> -8 [label="!b", style=bold, color="#FAA43A", dir=none]
|
||||
-8[label=<>,width=0,height=0,shape=none]
|
||||
-8 [label=<>,width=0,height=0,shape=none]
|
||||
-8 -> 4 [style=bold, color="#FAA43A"]
|
||||
-8 -> 3 [style=bold, color="#FAA43A"]
|
||||
4 [label="F(b)\n⓿"]
|
||||
|
|
|
|||
|
|
@ -1921,8 +1921,7 @@ State: 11 "t"
|
|||
EOF
|
||||
|
||||
expecterr input <<EOF
|
||||
input:4.8-12: alternation is not yet supported for initial states
|
||||
autfilt: failed to read automaton from input
|
||||
input:4.1-12: alternating automata only support a single initial state
|
||||
EOF
|
||||
|
||||
# Some alternation errors
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue