Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Spot
Spot
Commits
d15b5f43
Commit
d15b5f43
authored
Nov 09, 2015
by
Alexandre Lewkowicz
Committed by
Alexandre Duret-Lutz
Feb 12, 2016
Browse files
safra: Fix properties and use new API
* src/tests/safra.cc, src/twaalgos/safra.cc: Here.
parent
bb93f6e9
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/tests/safra.cc
View file @
d15b5f43
...
...
@@ -20,7 +20,8 @@
#include
<iostream>
#include
<cstring>
#include
"ltlparse/public.hh"
// ltl::parse
#include
"tl/parse.hh"
// spot::parse_infix_psl
#include
"tl/formula.hh"
// spot::formula
#include
"parseaut/public.hh"
#include
"twa/twagraph.hh"
#include
"twaalgos/degen.hh"
...
...
@@ -96,22 +97,19 @@ int main(int argc, char* argv[])
spot
::
twa_graph_ptr
res
;
if
(
in_ltl
)
{
spot
::
ltl
::
parse_error_list
pel
;
const
spot
::
ltl
::
formula
*
f
=
spot
::
ltl
::
parse_infix_psl
(
input
,
pel
);
if
(
spot
::
ltl
::
format_parse_errors
(
std
::
cerr
,
input
,
pel
))
spot
::
parse_error_list
pel
;
spot
::
formula
f
=
spot
::
parse_infix_psl
(
input
,
pel
);
if
(
spot
::
format_parse_errors
(
std
::
cerr
,
input
,
pel
))
return
2
;
spot
::
translator
trans
(
dict
);
trans
.
set_pref
(
spot
::
postprocessor
::
Deterministic
);
auto
tmp
=
trans
.
run
(
f
);
res
=
spot
::
tgba_determinisation
(
tmp
,
sim
,
pretty_print
,
scc_opt
);
f
->
destroy
();
}
else
if
(
in_hoa
)
{
spot
::
parse_aut_error_list
pel
;
auto
aut
=
spot
::
parse_aut
(
input
,
pel
,
dict
);
if
(
spot
::
format_parse_aut_errors
(
std
::
cerr
,
input
,
pel
))
auto
aut
=
spot
::
parse_aut
(
input
,
dict
);
if
(
aut
->
format_errors
(
std
::
cerr
))
return
2
;
res
=
tgba_determinisation
(
aut
->
aut
,
sim
,
pretty_print
,
scc_opt
);
}
...
...
src/twaalgos/safra.cc
View file @
d15b5f43
...
...
@@ -493,7 +493,7 @@ safra_state::compute_succs(const const_twa_graph_ptr& aut,
res
->
copy_ap_of
(
aut
);
res
->
prop_copy
(
aut
,
{
false
,
// state based
tru
e
,
// inherently_weak
fals
e
,
// inherently_weak
false
,
// deterministic
true
// stutter inv
});
...
...
@@ -550,7 +550,7 @@ safra_state::compute_succs(const const_twa_graph_ptr& aut,
// Acceptance is now min(odd) since we con emit Red on paths 0 with new opti
res
->
set_acceptance
(
sets
,
acc_cond
::
acc_code
::
parity
(
false
,
true
,
sets
));
res
->
prop_deterministic
(
true
);
res
->
prop_state_
based_
acc
(
false
);
res
->
prop_state_acc
(
false
);
if
(
bisimulation
)
res
=
simulation
(
res
);
if
(
pretty_print
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment