kill the ltl namespace
* NEWS: Mention it. * bench/stutter/stutter_invariance_formulas.cc, bench/stutter/stutter_invariance_randomgraph.cc, doc/mainpage.dox, doc/org/tut01.org, doc/org/tut02.org, doc/org/tut10.org, doc/tl/tl.tex, iface/ltsmin/ltsmin.cc, iface/ltsmin/ltsmin.hh, iface/ltsmin/modelcheck.cc, src/bin/autfilt.cc, src/bin/common_aoutput.cc, src/bin/common_aoutput.hh, src/bin/common_finput.cc, src/bin/common_finput.hh, src/bin/common_output.cc, src/bin/common_output.hh, src/bin/common_r.hh, src/bin/common_trans.cc, src/bin/common_trans.hh, src/bin/dstar2tgba.cc, src/bin/genltl.cc, src/bin/ltl2tgba.cc, src/bin/ltl2tgta.cc, src/bin/ltlcross.cc, src/bin/ltldo.cc, src/bin/ltlfilt.cc, src/bin/ltlgrind.cc, src/bin/randaut.cc, src/bin/randltl.cc, src/kripke/kripkeexplicit.cc, src/kripke/kripkeexplicit.hh, src/kripkeparse/kripkeparse.yy, src/kripkeparse/public.hh, src/ltlparse/fmterror.cc, src/ltlparse/ltlparse.yy, src/ltlparse/ltlscan.ll, src/ltlparse/parsedecl.hh, src/ltlparse/public.hh, src/parseaut/parseaut.yy, src/parseaut/public.hh, src/tests/checkpsl.cc, src/tests/checkta.cc, src/tests/complementation.cc, src/tests/consterm.cc, src/tests/emptchk.cc, src/tests/equalsf.cc, src/tests/ikwiad.cc, src/tests/kind.cc, src/tests/length.cc, src/tests/ltlprod.cc, src/tests/ltlrel.cc, src/tests/parse.test, src/tests/parse_print_test.cc, src/tests/randtgba.cc, src/tests/readltl.cc, src/tests/reduc.cc, src/tests/syntimpl.cc, src/tests/taatgba.cc, src/tests/tostring.cc, src/tests/tostring.test, src/tl/apcollect.cc, src/tl/apcollect.hh, src/tl/contain.cc, src/tl/contain.hh, src/tl/declenv.cc, src/tl/declenv.hh, src/tl/defaultenv.cc, src/tl/defaultenv.hh, src/tl/dot.cc, src/tl/dot.hh, src/tl/environment.hh, src/tl/exclusive.cc, src/tl/exclusive.hh, src/tl/formula.cc, src/tl/formula.hh, src/tl/length.cc, src/tl/length.hh, src/tl/mark.cc, src/tl/mark.hh, src/tl/mutation.cc, src/tl/mutation.hh, src/tl/nenoform.cc, src/tl/nenoform.hh, src/tl/print.cc, src/tl/print.hh, src/tl/randomltl.cc, src/tl/randomltl.hh, src/tl/relabel.cc, src/tl/relabel.hh, src/tl/remove_x.cc, src/tl/remove_x.hh, src/tl/simpfg.cc, src/tl/simpfg.hh, src/tl/simplify.cc, src/tl/simplify.hh, src/tl/snf.cc, src/tl/snf.hh, src/tl/unabbrev.cc, src/tl/unabbrev.hh, src/twa/bdddict.cc, src/twa/bdddict.hh, src/twa/bddprint.cc, src/twa/formula2bdd.cc, src/twa/formula2bdd.hh, src/twa/taatgba.cc, src/twa/taatgba.hh, src/twa/twa.hh, src/twa/twagraph.cc, src/twa/twagraph.hh, src/twaalgos/compsusp.cc, src/twaalgos/compsusp.hh, src/twaalgos/ltl2taa.cc, src/twaalgos/ltl2taa.hh, src/twaalgos/ltl2tgba_fm.cc, src/twaalgos/ltl2tgba_fm.hh, src/twaalgos/minimize.cc, src/twaalgos/minimize.hh, src/twaalgos/neverclaim.cc, src/twaalgos/postproc.cc, src/twaalgos/postproc.hh, src/twaalgos/powerset.cc, src/twaalgos/powerset.hh, src/twaalgos/randomgraph.cc, src/twaalgos/randomgraph.hh, src/twaalgos/relabel.cc, src/twaalgos/relabel.hh, src/twaalgos/remprop.cc, src/twaalgos/remprop.hh, src/twaalgos/stats.cc, src/twaalgos/stats.hh, src/twaalgos/stutter.cc, src/twaalgos/stutter.hh, src/twaalgos/translate.cc, src/twaalgos/translate.hh, wrap/python/spot_impl.i: Remove the ltl namespace.
This commit is contained in:
parent
6ded5e75c4
commit
cb39210166
137 changed files with 10771 additions and 10919 deletions
17
NEWS
17
NEWS
|
|
@ -28,9 +28,9 @@ New in spot 1.99.3a (not yet released)
|
|||
* The class hierarchy for temporal formulas has been entirely
|
||||
rewritten. This change is actually quite massive (~13200 lines
|
||||
removed, ~8200 lines added), and brings some nice benefits:
|
||||
- LTL/PSL formulas are now represented by lightweight ltl::formula
|
||||
objects (instead of ltl::formula* pointers) that perform
|
||||
reference counting automatically.
|
||||
- LTL/PSL formulas are now represented by lightweight formula
|
||||
objects (instead of pointers to children of an abstract formula
|
||||
class) that perform reference counting automatically.
|
||||
- There is no hierachy anymore: all operators are represented by a
|
||||
single type of node in the syntax tree, and an enumerator is
|
||||
used to distinguish between operators.
|
||||
|
|
@ -41,10 +41,13 @@ New in spot 1.99.3a (not yet released)
|
|||
more friendly, and several algorithms that spanned a few pages
|
||||
have been reduced to a few lines.
|
||||
|
||||
* The source directories ltlast/, ltlenv/, and ltlvisit/, have been
|
||||
merged into a single tl/ directory (for temporal logic). This is
|
||||
motivated by the fact that these formulas are not restricted to
|
||||
LTL, and by the fact that we no longuer use the "visitor" pattern.
|
||||
* Directories ltlast/, ltlenv/, and ltlvisit/, have been merged into
|
||||
a single tl/ directory (for temporal logic). This is motivated by
|
||||
the fact that these formulas are not restricted to LTL, and by the
|
||||
fact that we no longuer use the "visitor" pattern.
|
||||
|
||||
* For similar reasons, the spot::ltl namespace has been merged
|
||||
with the spot namespace.
|
||||
|
||||
New in spot 1.99.3 (2015-08-26)
|
||||
|
||||
|
|
|
|||
|
|
@ -62,12 +62,12 @@ namespace
|
|||
}
|
||||
|
||||
int
|
||||
process_formula(spot::ltl::formula f, const char*, int)
|
||||
process_formula(spot::formula f, const char*, int)
|
||||
{
|
||||
spot::twa_graph_ptr a = trans.run(f);
|
||||
spot::twa_graph_ptr na = trans.run(spot::ltl::formula::Not(f));
|
||||
spot::ltl::atomic_prop_set* ap = spot::ltl::atomic_prop_collect(f);
|
||||
bdd apdict = spot::ltl::atomic_prop_collect_as_bdd(f, a);
|
||||
spot::twa_graph_ptr na = trans.run(spot::formula::Not(f));
|
||||
spot::atomic_prop_set* ap = spot::atomic_prop_collect(f);
|
||||
bdd apdict = spot::atomic_prop_collect_as_bdd(f, a);
|
||||
|
||||
std::cout << formula << ',' << ap->size() << ',';
|
||||
stats.print(a);
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ main(int argc, char** argv)
|
|||
constexpr unsigned n = 10;
|
||||
|
||||
// random ap set
|
||||
auto ap = spot::ltl::create_atomic_prop_set(props_n);
|
||||
auto ap = spot::create_atomic_prop_set(props_n);
|
||||
// ap set as bdd
|
||||
bdd apdict = bddtrue;
|
||||
for (auto& i: ap)
|
||||
|
|
|
|||
|
|
@ -19,12 +19,12 @@
|
|||
///
|
||||
/// \section pointers Handy starting points
|
||||
///
|
||||
/// \li spot::ltl::formula Base class for an LTL or PSL formula.
|
||||
/// \li spot::ltl::parse_infix_psl Parsing a text string into a
|
||||
/// spot::ltl::formula.
|
||||
/// \li spot::formula Base class for an LTL or PSL formula.
|
||||
/// \li spot::parse_infix_psl Parsing a text string into a
|
||||
/// spot::formula.
|
||||
/// \li spot::twa Base class for Transition-based
|
||||
/// ω-Automata.
|
||||
/// \li spot::translator Convert a spot::ltl::formula into a
|
||||
/// \li spot::translator Convert a spot::formula into a
|
||||
/// spot::tgba.
|
||||
/// \li spot::kripke Base class for Kripke structures.
|
||||
/// \li spot::twa_product On-the-fly product of two spot::twa.
|
||||
|
|
|
|||
|
|
@ -71,8 +71,8 @@ exceptions.
|
|||
|
||||
int main()
|
||||
{
|
||||
print_latex_psl(std::cout, spot::ltl::parse_formula("[]<>p0 || <>[]p1")) << '\n';
|
||||
spot::ltl::formula f = spot::ltl::parse_formula("& & G p0 p1 p2");
|
||||
print_latex_psl(std::cout, spot::parse_formula("[]<>p0 || <>[]p1")) << '\n';
|
||||
spot::formula f = spot::parse_formula("& & G p0 p1 p2");
|
||||
print_lbt_ltl(std::cout, f) << '\n';
|
||||
print_spin_ltl(std::cout, f, true) << '\n';
|
||||
return 0;
|
||||
|
|
@ -110,9 +110,9 @@ Here is how to call the infix parser explicitly,:
|
|||
int main()
|
||||
{
|
||||
std::string input = "[]<>p0 || <>[]p1";
|
||||
spot::ltl::parse_error_list pel;
|
||||
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 1;
|
||||
print_latex_psl(std::cout, f) << '\n';
|
||||
return 0;
|
||||
|
|
@ -152,11 +152,11 @@ with the "fixed" formula if you wish. Here is an example:
|
|||
int main()
|
||||
{
|
||||
std::string input = "(a U b))";
|
||||
spot::ltl::parse_error_list pel;
|
||||
spot::ltl::formula f = spot::ltl::parse_infix_psl(input, pel);
|
||||
spot::parse_error_list pel;
|
||||
spot::formula f = spot::parse_infix_psl(input, pel);
|
||||
// Use std::cout instead of std::cerr because we can only
|
||||
// show the output of std::cout in this documentation.
|
||||
(void) spot::ltl::format_parse_errors(std::cout, input, pel);
|
||||
(void) spot::format_parse_errors(std::cout, input, pel);
|
||||
if (f == nullptr)
|
||||
return 1;
|
||||
std::cout << "Parsed formula: ";
|
||||
|
|
@ -194,9 +194,9 @@ of =parse_infix_psl()=.
|
|||
int main()
|
||||
{
|
||||
std::string input = "& & G p0 p1 p2";
|
||||
spot::ltl::parse_error_list pel;
|
||||
spot::ltl::formula f = spot::ltl::parse_prefix_ltl(input, pel);
|
||||
if (spot::ltl::format_parse_errors(std::cerr, input, pel))
|
||||
spot::parse_error_list pel;
|
||||
spot::formula f = spot::parse_prefix_ltl(input, pel);
|
||||
if (spot::format_parse_errors(std::cerr, input, pel))
|
||||
return 1;
|
||||
print_lbt_ltl(std::cout, f) << '\n';
|
||||
print_spin_ltl(std::cout, f, true) << '\n';
|
||||
|
|
@ -236,9 +236,9 @@ For instance, let's see what happens if a PSL formulas is passed to
|
|||
int main()
|
||||
{
|
||||
std::string input = "{a*;b}<>->(a U (b & GF c))";
|
||||
spot::ltl::parse_error_list pel;
|
||||
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 1;
|
||||
print_spin_ltl(std::cout, f) << '\n';
|
||||
return 0;
|
||||
|
|
@ -266,9 +266,9 @@ The first is to simply diagnose non-LTL formulas.
|
|||
int main()
|
||||
{
|
||||
std::string input = "{a*;b}<>->(a U (b & GF c))";
|
||||
spot::ltl::parse_error_list pel;
|
||||
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 1;
|
||||
if (!f.is_ltl_formula())
|
||||
{
|
||||
|
|
@ -296,13 +296,13 @@ prepared to reject the formula any way. In our example, we are lucky
|
|||
int main()
|
||||
{
|
||||
std::string input = "{a*;b}<>->(a U (b & GF c))";
|
||||
spot::ltl::parse_error_list pel;
|
||||
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 1;
|
||||
if (!f.is_ltl_formula())
|
||||
{
|
||||
spot::ltl::ltl_simplifier simp;
|
||||
spot::ltl_simplifier simp;
|
||||
f = simp.simplify(f);
|
||||
}
|
||||
if (!f.is_ltl_formula())
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ print(g.to_str('spin', True))
|
|||
|
||||
* C++
|
||||
|
||||
The =spot::ltl::relabeling_map= is just a =std::map= with a custom
|
||||
The =spot::relabeling_map= is just a =std::map= with a custom
|
||||
destructor.
|
||||
|
||||
#+BEGIN_SRC C++ :results verbatim :exports both
|
||||
|
|
@ -87,12 +87,12 @@ destructor.
|
|||
int main()
|
||||
{
|
||||
std::string input = "\"Proc@Here\" U (\"var > 10\" | \"var < 4\")";
|
||||
spot::ltl::parse_error_list pel;
|
||||
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 1;
|
||||
spot::ltl::relabeling_map m;
|
||||
f = spot::ltl::relabel(f, spot::ltl::Pnn, &m);
|
||||
spot::relabeling_map m;
|
||||
f = spot::relabel(f, spot::Pnn, &m);
|
||||
for (auto& i: m)
|
||||
{
|
||||
std::cout << "#define ";
|
||||
|
|
@ -115,8 +115,8 @@ destructor.
|
|||
|
||||
** Two ways to name atomic propositions
|
||||
|
||||
Instead of =--relabel=pnn= (or =spot.Pnn=, or =spot::ltl::Pnn=), you can
|
||||
actually use =--relabel=abc= (or =spot.Abc=, or =spot::ltl::Abc=) to have
|
||||
Instead of =--relabel=pnn= (or =spot.Pnn=, or =spot::Pnn=), you can
|
||||
actually use =--relabel=abc= (or =spot.Abc=, or =spot::Abc=) to have
|
||||
the atomic propositions named =a=, =b=, =c=, etc.
|
||||
|
||||
** Relabeling Boolean sub-expressions
|
||||
|
|
|
|||
|
|
@ -137,9 +137,9 @@ never claim is done via the =print_never_claim= function.
|
|||
int main()
|
||||
{
|
||||
std::string input = "[]<>p0 || <>[]p1";
|
||||
spot::ltl::parse_error_list pel;
|
||||
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 1;
|
||||
spot::translator trans;
|
||||
trans.set_type(spot::postprocessor::BA);
|
||||
|
|
|
|||
|
|
@ -1001,7 +1001,7 @@ both right-associative, other have only $\IMPLIES$ as right-associative.
|
|||
|
||||
When Spot builds a formula (represented by an AST with shared
|
||||
subtrees) it computes a set of properties for each node. These
|
||||
properties can be queried from any \texttt{spot::ltl::formula}
|
||||
properties can be queried from any \texttt{spot::formula}
|
||||
instance using the following methods:
|
||||
|
||||
\noindent
|
||||
|
|
|
|||
|
|
@ -323,10 +323,10 @@ namespace spot
|
|||
|
||||
|
||||
int
|
||||
convert_aps(const ltl::atomic_prop_set* aps,
|
||||
convert_aps(const atomic_prop_set* aps,
|
||||
const spins_interface* d,
|
||||
bdd_dict_ptr dict,
|
||||
ltl::formula dead,
|
||||
formula dead,
|
||||
prop_set& out)
|
||||
{
|
||||
int errors = 0;
|
||||
|
|
@ -353,7 +353,7 @@ namespace spot
|
|||
enum_map[i].emplace(d->get_type_value_name(i, j), j);
|
||||
}
|
||||
|
||||
for (ltl::atomic_prop_set::const_iterator ap = aps->begin();
|
||||
for (atomic_prop_set::const_iterator ap = aps->begin();
|
||||
ap != aps->end(); ++ap)
|
||||
{
|
||||
if (*ap == dead)
|
||||
|
|
@ -602,7 +602,7 @@ namespace spot
|
|||
public:
|
||||
|
||||
spins_kripke(const spins_interface* d, const bdd_dict_ptr& dict,
|
||||
const spot::prop_set* ps, ltl::formula dead,
|
||||
const spot::prop_set* ps, formula dead,
|
||||
int compress)
|
||||
: kripke(dict),
|
||||
d_(d),
|
||||
|
|
@ -1016,8 +1016,8 @@ namespace spot
|
|||
|
||||
kripke_ptr
|
||||
load_ltsmin(const std::string& file_arg, const bdd_dict_ptr& dict,
|
||||
const ltl::atomic_prop_set* to_observe,
|
||||
const ltl::formula dead, int compress, bool verbose)
|
||||
const atomic_prop_set* to_observe,
|
||||
const formula dead, int compress, bool verbose)
|
||||
{
|
||||
std::string file;
|
||||
if (file_arg.find_first_of("/\\") != std::string::npos)
|
||||
|
|
|
|||
|
|
@ -57,7 +57,7 @@ namespace spot
|
|||
// \a verbose whether to output verbose messages
|
||||
SPOT_API kripke_ptr
|
||||
load_ltsmin(const std::string& file, const bdd_dict_ptr& dict,
|
||||
const ltl::atomic_prop_set* to_observe,
|
||||
ltl::formula dead = ltl::formula::tt(),
|
||||
const atomic_prop_set* to_observe,
|
||||
formula dead = formula::tt(),
|
||||
int compress = 0, bool verbose = true);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -150,11 +150,11 @@ checked_main(int argc, char **argv)
|
|||
if (argc != 3)
|
||||
syntax(argv[0]);
|
||||
|
||||
spot::ltl::default_environment& env =
|
||||
spot::ltl::default_environment::instance();
|
||||
spot::default_environment& env =
|
||||
spot::default_environment::instance();
|
||||
|
||||
|
||||
spot::ltl::atomic_prop_set ap;
|
||||
spot::atomic_prop_set ap;
|
||||
auto dict = spot::make_bdd_dict();
|
||||
spot::const_kripke_ptr model = nullptr;
|
||||
spot::const_twa_ptr prop = nullptr;
|
||||
|
|
@ -162,16 +162,16 @@ checked_main(int argc, char **argv)
|
|||
spot::emptiness_check_instantiator_ptr echeck_inst = nullptr;
|
||||
int exit_code = 0;
|
||||
spot::postprocessor post;
|
||||
spot::ltl::formula deadf = nullptr;
|
||||
spot::ltl::formula f = nullptr;
|
||||
spot::formula deadf = nullptr;
|
||||
spot::formula f = nullptr;
|
||||
|
||||
if (!dead || !strcasecmp(dead, "true"))
|
||||
{
|
||||
deadf = spot::ltl::formula::tt();
|
||||
deadf = spot::formula::tt();
|
||||
}
|
||||
else if (!strcasecmp(dead, "false"))
|
||||
{
|
||||
deadf = spot::ltl::formula::ff();
|
||||
deadf = spot::formula::ff();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -193,9 +193,9 @@ checked_main(int argc, char **argv)
|
|||
|
||||
tm.start("parsing formula");
|
||||
{
|
||||
spot::ltl::parse_error_list pel;
|
||||
f = spot::ltl::parse_infix_psl(argv[2], pel, env, false);
|
||||
exit_code = spot::ltl::format_parse_errors(std::cerr, argv[2], pel);
|
||||
spot::parse_error_list pel;
|
||||
f = spot::parse_infix_psl(argv[2], pel, env, false);
|
||||
exit_code = spot::format_parse_errors(std::cerr, argv[2], pel);
|
||||
}
|
||||
tm.stop("parsing formula");
|
||||
|
||||
|
|
@ -366,6 +366,6 @@ main(int argc, char **argv)
|
|||
auto exit_code = checked_main(argc, argv);
|
||||
|
||||
// Additional checks to debug reference counts in formulas.
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
exit(exit_code);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -505,7 +505,7 @@ namespace
|
|||
}
|
||||
|
||||
int
|
||||
process_formula(spot::ltl::formula, const char*, int)
|
||||
process_formula(spot::formula, const char*, int)
|
||||
{
|
||||
SPOT_UNREACHABLE();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -287,7 +287,7 @@ automaton_printer::automaton_printer(stat_style input)
|
|||
|
||||
void
|
||||
automaton_printer::print(const spot::twa_graph_ptr& aut,
|
||||
spot::ltl::formula f,
|
||||
spot::formula f,
|
||||
// Input location for errors and statistics.
|
||||
const char* filename,
|
||||
int loc,
|
||||
|
|
|
|||
|
|
@ -107,7 +107,7 @@ public:
|
|||
std::ostream&
|
||||
print(const spot::const_parsed_aut_ptr& haut,
|
||||
const spot::const_twa_graph_ptr& aut,
|
||||
spot::ltl::formula f,
|
||||
spot::formula f,
|
||||
const char* filename, int loc, double run_time)
|
||||
{
|
||||
filename_ = filename ? filename : "";
|
||||
|
|
@ -225,7 +225,7 @@ public:
|
|||
|
||||
void
|
||||
print(const spot::twa_graph_ptr& aut,
|
||||
spot::ltl::formula f = nullptr,
|
||||
spot::formula f = nullptr,
|
||||
// Input location for errors and statistics.
|
||||
const char* filename = nullptr,
|
||||
int loc = -1,
|
||||
|
|
|
|||
|
|
@ -77,14 +77,14 @@ parse_opt_finput(int key, char* arg, struct argp_state*)
|
|||
return 0;
|
||||
}
|
||||
|
||||
spot::ltl::formula
|
||||
parse_formula(const std::string& s, spot::ltl::parse_error_list& pel)
|
||||
spot::formula
|
||||
parse_formula(const std::string& s, spot::parse_error_list& pel)
|
||||
{
|
||||
if (lbt_input)
|
||||
return spot::ltl::parse_prefix_ltl(s, pel);
|
||||
return spot::parse_prefix_ltl(s, pel);
|
||||
else
|
||||
return spot::ltl::parse_infix_psl
|
||||
(s, pel, spot::ltl::default_environment::instance(), false, lenient);
|
||||
return spot::parse_infix_psl
|
||||
(s, pel, spot::default_environment::instance(), false, lenient);
|
||||
}
|
||||
|
||||
job_processor::job_processor()
|
||||
|
|
@ -109,14 +109,14 @@ job_processor::process_string(const std::string& input,
|
|||
const char* filename,
|
||||
int linenum)
|
||||
{
|
||||
spot::ltl::parse_error_list pel;
|
||||
spot::parse_error_list pel;
|
||||
auto f = parse_formula(input, pel);
|
||||
|
||||
if (!f || !pel.empty())
|
||||
{
|
||||
if (filename)
|
||||
error_at_line(0, 0, filename, linenum, "parse error:");
|
||||
spot::ltl::format_parse_errors(std::cerr, input, pel);
|
||||
spot::format_parse_errors(std::cerr, input, pel);
|
||||
return 1;
|
||||
}
|
||||
return process_formula(f, filename, linenum);
|
||||
|
|
|
|||
|
|
@ -44,8 +44,8 @@ extern const struct argp finput_argp;
|
|||
|
||||
int parse_opt_finput(int key, char* arg, struct argp_state* state);
|
||||
|
||||
spot::ltl::formula
|
||||
parse_formula(const std::string& s, spot::ltl::parse_error_list& error_list);
|
||||
spot::formula
|
||||
parse_formula(const std::string& s, spot::parse_error_list& error_list);
|
||||
|
||||
|
||||
class job_processor
|
||||
|
|
@ -58,7 +58,7 @@ public:
|
|||
virtual ~job_processor();
|
||||
|
||||
virtual int
|
||||
process_formula(spot::ltl::formula f,
|
||||
process_formula(spot::formula f,
|
||||
const char* filename = nullptr, int linenum = 0) = 0;
|
||||
|
||||
virtual int
|
||||
|
|
|
|||
|
|
@ -70,10 +70,10 @@ const struct argp output_argp = { options, parse_opt_output,
|
|||
|
||||
static
|
||||
void
|
||||
report_not_ltl(spot::ltl::formula f,
|
||||
report_not_ltl(spot::formula f,
|
||||
const char* filename, int linenum, const char* syn)
|
||||
{
|
||||
std::string s = spot::ltl::str_psl(f);
|
||||
std::string s = spot::str_psl(f);
|
||||
static const char msg[] =
|
||||
"formula '%s' cannot be written %s's syntax because it is not LTL";
|
||||
if (filename)
|
||||
|
|
@ -84,36 +84,36 @@ report_not_ltl(spot::ltl::formula f,
|
|||
|
||||
std::ostream&
|
||||
stream_formula(std::ostream& out,
|
||||
spot::ltl::formula f, const char* filename, int linenum)
|
||||
spot::formula f, const char* filename, int linenum)
|
||||
{
|
||||
switch (output_format)
|
||||
{
|
||||
case lbt_output:
|
||||
if (f.is_ltl_formula())
|
||||
spot::ltl::print_lbt_ltl(out, f);
|
||||
spot::print_lbt_ltl(out, f);
|
||||
else
|
||||
report_not_ltl(f, filename, linenum, "LBT");
|
||||
break;
|
||||
case spot_output:
|
||||
spot::ltl::print_psl(out, f, full_parenth);
|
||||
spot::print_psl(out, f, full_parenth);
|
||||
break;
|
||||
case spin_output:
|
||||
if (f.is_ltl_formula())
|
||||
spot::ltl::print_spin_ltl(out, f, full_parenth);
|
||||
spot::print_spin_ltl(out, f, full_parenth);
|
||||
else
|
||||
report_not_ltl(f, filename, linenum, "Spin");
|
||||
break;
|
||||
case wring_output:
|
||||
if (f.is_ltl_formula())
|
||||
spot::ltl::print_wring_ltl(out, f);
|
||||
spot::print_wring_ltl(out, f);
|
||||
else
|
||||
report_not_ltl(f, filename, linenum, "Wring");
|
||||
break;
|
||||
case utf8_output:
|
||||
spot::ltl::print_utf8_psl(out, f, full_parenth);
|
||||
spot::print_utf8_psl(out, f, full_parenth);
|
||||
break;
|
||||
case latex_output:
|
||||
spot::ltl::print_latex_psl(out, f, full_parenth);
|
||||
spot::print_latex_psl(out, f, full_parenth);
|
||||
break;
|
||||
case count_output:
|
||||
case quiet_output:
|
||||
|
|
@ -124,7 +124,7 @@ stream_formula(std::ostream& out,
|
|||
|
||||
static void
|
||||
stream_escapable_formula(std::ostream& os,
|
||||
spot::ltl::formula f,
|
||||
spot::formula f,
|
||||
const char* filename, int linenum)
|
||||
{
|
||||
if (escape_csv)
|
||||
|
|
@ -146,7 +146,7 @@ namespace
|
|||
{
|
||||
struct formula_with_location
|
||||
{
|
||||
spot::ltl::formula f;
|
||||
spot::formula f;
|
||||
const char* filename;
|
||||
int line;
|
||||
const char* prefix;
|
||||
|
|
@ -260,7 +260,7 @@ parse_opt_output(int key, char* arg, struct argp_state*)
|
|||
|
||||
static void
|
||||
output_formula(std::ostream& out,
|
||||
spot::ltl::formula f,
|
||||
spot::formula f,
|
||||
const char* filename = nullptr, int linenum = 0,
|
||||
const char* prefix = nullptr, const char* suffix = nullptr)
|
||||
{
|
||||
|
|
@ -286,7 +286,7 @@ void
|
|||
}
|
||||
|
||||
void
|
||||
output_formula_checked(spot::ltl::formula f,
|
||||
output_formula_checked(spot::formula f,
|
||||
const char* filename, int linenum,
|
||||
const char* prefix, const char* suffix)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -43,20 +43,20 @@ int parse_opt_output(int key, char* arg, struct argp_state* state);
|
|||
// Low-level output
|
||||
std::ostream&
|
||||
stream_formula(std::ostream& out,
|
||||
spot::ltl::formula f, const char* filename, int linenum);
|
||||
spot::formula f, const char* filename, int linenum);
|
||||
|
||||
void output_formula_checked(spot::ltl::formula f,
|
||||
void output_formula_checked(spot::formula f,
|
||||
const char* filename = nullptr, int linenum = 0,
|
||||
const char* prefix = nullptr,
|
||||
const char* suffix = nullptr);
|
||||
|
||||
|
||||
class printable_formula:
|
||||
public spot::printable_value<spot::ltl::formula>
|
||||
public spot::printable_value<spot::formula>
|
||||
{
|
||||
public:
|
||||
printable_formula&
|
||||
operator=(spot::ltl::formula new_val)
|
||||
operator=(spot::formula new_val)
|
||||
{
|
||||
val_ = new_val;
|
||||
return *this;
|
||||
|
|
@ -79,7 +79,7 @@ public:
|
|||
|
||||
std::ostream&
|
||||
print(const spot::const_twa_graph_ptr& aut,
|
||||
spot::ltl::formula f = nullptr,
|
||||
spot::formula f = nullptr,
|
||||
double run_time = -1.)
|
||||
{
|
||||
formula_ = f;
|
||||
|
|
|
|||
|
|
@ -44,4 +44,4 @@
|
|||
extern int simplification_level;
|
||||
|
||||
void parse_r(const char* arg);
|
||||
spot::ltl::ltl_simplifier_options simplifier_options();
|
||||
spot::ltl_simplifier_options simplifier_options();
|
||||
|
|
|
|||
|
|
@ -290,16 +290,16 @@ translator_runner::formula() const
|
|||
}
|
||||
|
||||
void
|
||||
translator_runner::round_formula(spot::ltl::formula f, unsigned serial)
|
||||
translator_runner::round_formula(spot::formula f, unsigned serial)
|
||||
{
|
||||
if (has('f') || has('F'))
|
||||
string_ltl_spot = spot::ltl::str_psl(f, true);
|
||||
string_ltl_spot = spot::str_psl(f, true);
|
||||
if (has('s') || has('S'))
|
||||
string_ltl_spin = spot::ltl::str_spin_ltl(f, true);
|
||||
string_ltl_spin = spot::str_spin_ltl(f, true);
|
||||
if (has('l') || has('L'))
|
||||
string_ltl_lbt = spot::ltl::str_lbt_ltl(f);
|
||||
string_ltl_lbt = spot::str_lbt_ltl(f);
|
||||
if (has('w') || has('W'))
|
||||
string_ltl_wring = spot::ltl::str_wring_ltl(f);
|
||||
string_ltl_wring = spot::str_wring_ltl(f);
|
||||
if (has('F'))
|
||||
string_to_tmp(string_ltl_spot, serial, filename_ltl_spot);
|
||||
if (has('S'))
|
||||
|
|
|
|||
|
|
@ -94,7 +94,7 @@ public:
|
|||
bool no_output_allowed = false);
|
||||
void string_to_tmp(std::string& str, unsigned n, std::string& tmpname);
|
||||
const std::string& formula() const;
|
||||
void round_formula(spot::ltl::formula f, unsigned serial);
|
||||
void round_formula(spot::formula f, unsigned serial);
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ namespace
|
|||
}
|
||||
|
||||
int
|
||||
process_formula(spot::ltl::formula, const char*, int)
|
||||
process_formula(spot::formula, const char*, int)
|
||||
{
|
||||
SPOT_UNREACHABLE();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -90,7 +90,6 @@
|
|||
#include "tl/relabel.hh"
|
||||
|
||||
using namespace spot;
|
||||
using namespace spot::ltl;
|
||||
|
||||
const char argp_program_doc[] ="\
|
||||
Generate temporal logic formulas from predefined scalable patterns.";
|
||||
|
|
|
|||
|
|
@ -139,16 +139,16 @@ namespace
|
|||
}
|
||||
|
||||
int
|
||||
process_formula(spot::ltl::formula f,
|
||||
process_formula(spot::formula f,
|
||||
const char* filename = nullptr, int linenum = 0)
|
||||
{
|
||||
// This should not happen, because the parser we use can only
|
||||
// read PSL/LTL formula, but since our ltl::formula type can
|
||||
// read PSL/LTL formula, but since our formula type can
|
||||
// represent more than PSL formula, let's make this
|
||||
// future-proof.
|
||||
if (!f.is_psl_formula())
|
||||
{
|
||||
std::string s = spot::ltl::str_psl(f);
|
||||
std::string s = spot::str_psl(f);
|
||||
error_at_line(2, 0, filename, linenum,
|
||||
"formula '%s' is not an LTL or PSL formula",
|
||||
s.c_str());
|
||||
|
|
|
|||
|
|
@ -170,18 +170,18 @@ namespace
|
|||
}
|
||||
|
||||
int
|
||||
process_formula(spot::ltl::formula f,
|
||||
process_formula(spot::formula f,
|
||||
const char* filename = nullptr, int linenum = 0)
|
||||
{
|
||||
auto aut = trans.run(&f);
|
||||
|
||||
// This should not happen, because the parser we use can only
|
||||
// read PSL/LTL formula, but since our ltl::formula type can
|
||||
// read PSL/LTL formula, but since our formula type can
|
||||
// represent more than PSL formula, let's make this
|
||||
// future-proof.
|
||||
if (!f.is_psl_formula())
|
||||
{
|
||||
std::string s = spot::ltl::str_psl(f);
|
||||
std::string s = spot::str_psl(f);
|
||||
error_at_line(2, 0, filename, linenum,
|
||||
"formula '%s' is not an LTL or PSL formula",
|
||||
s.c_str());
|
||||
|
|
|
|||
|
|
@ -819,7 +819,7 @@ namespace
|
|||
}
|
||||
|
||||
typedef
|
||||
std::unordered_set<spot::ltl::formula> fset_t;
|
||||
std::unordered_set<spot::formula> fset_t;
|
||||
|
||||
|
||||
class processor: public job_processor
|
||||
|
|
@ -838,14 +838,14 @@ namespace
|
|||
const char* filename,
|
||||
int linenum)
|
||||
{
|
||||
spot::ltl::parse_error_list pel;
|
||||
spot::ltl::formula f = parse_formula(input, pel);
|
||||
spot::parse_error_list pel;
|
||||
spot::formula f = parse_formula(input, pel);
|
||||
|
||||
if (!f || !pel.empty())
|
||||
{
|
||||
if (filename)
|
||||
error_at_line(0, 0, filename, linenum, "parse error:");
|
||||
spot::ltl::format_parse_errors(std::cerr, input, pel);
|
||||
spot::format_parse_errors(std::cerr, input, pel);
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
|
@ -856,7 +856,7 @@ namespace
|
|||
if (res && grind_output)
|
||||
{
|
||||
std::string bogus = input;
|
||||
std::vector<spot::ltl::formula> mutations;
|
||||
std::vector<spot::formula> mutations;
|
||||
unsigned mutation_count;
|
||||
unsigned mutation_max;
|
||||
while (res)
|
||||
|
|
@ -886,9 +886,9 @@ namespace
|
|||
if (res)
|
||||
{
|
||||
if (lbt_input)
|
||||
bogus = spot::ltl::str_lbt_ltl(f);
|
||||
bogus = spot::str_lbt_ltl(f);
|
||||
else
|
||||
bogus = spot::ltl::str_psl(f);
|
||||
bogus = spot::str_psl(f);
|
||||
if (bogus_output)
|
||||
bogus_output->ostream() << bogus << std::endl;
|
||||
}
|
||||
|
|
@ -938,7 +938,7 @@ namespace
|
|||
}
|
||||
|
||||
int
|
||||
process_formula(spot::ltl::formula f,
|
||||
process_formula(spot::formula f,
|
||||
const char* filename = nullptr, int linenum = 0)
|
||||
{
|
||||
static unsigned round = 0;
|
||||
|
|
@ -947,7 +947,7 @@ namespace
|
|||
// output, relabel the formula.
|
||||
if (!f.has_lbt_atomic_props() &&
|
||||
(runner.has('l') || runner.has('L') || runner.has('T')))
|
||||
f = spot::ltl::relabel(f, spot::ltl::Pnn);
|
||||
f = spot::relabel(f, spot::Pnn);
|
||||
|
||||
// ---------- Positive Formula ----------
|
||||
|
||||
|
|
@ -1028,7 +1028,7 @@ namespace
|
|||
nstats = &vstats[n + 1];
|
||||
nstats->resize(m);
|
||||
|
||||
spot::ltl::formula nf = spot::ltl::formula::Not(f);
|
||||
spot::formula nf = spot::formula::Not(f);
|
||||
|
||||
if (!allow_dups)
|
||||
{
|
||||
|
|
@ -1143,7 +1143,7 @@ namespace
|
|||
std::cerr << "Gathering statistics..." << std::endl;
|
||||
}
|
||||
|
||||
spot::ltl::atomic_prop_set* ap = spot::ltl::atomic_prop_collect(f);
|
||||
spot::atomic_prop_set* ap = spot::atomic_prop_collect(f);
|
||||
|
||||
if (want_stats)
|
||||
for (size_t i = 0; i < m; ++i)
|
||||
|
|
|
|||
|
|
@ -237,14 +237,14 @@ namespace
|
|||
const char* filename,
|
||||
int linenum)
|
||||
{
|
||||
spot::ltl::parse_error_list pel;
|
||||
spot::ltl::formula f = parse_formula(input, pel);
|
||||
spot::parse_error_list pel;
|
||||
spot::formula f = parse_formula(input, pel);
|
||||
|
||||
if (!f || !pel.empty())
|
||||
{
|
||||
if (filename)
|
||||
error_at_line(0, 0, filename, linenum, "parse error:");
|
||||
spot::ltl::format_parse_errors(std::cerr, input, pel);
|
||||
spot::format_parse_errors(std::cerr, input, pel);
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
|
@ -255,10 +255,10 @@ namespace
|
|||
|
||||
|
||||
int
|
||||
process_formula(spot::ltl::formula f,
|
||||
process_formula(spot::formula f,
|
||||
const char* filename = nullptr, int linenum = 0)
|
||||
{
|
||||
std::unique_ptr<spot::ltl::relabeling_map> relmap;
|
||||
std::unique_ptr<spot::relabeling_map> relmap;
|
||||
|
||||
// If atomic propositions are incompatible with one of the
|
||||
// output, relabel the formula.
|
||||
|
|
@ -267,8 +267,8 @@ namespace
|
|||
|| (!f.has_spin_atomic_props() &&
|
||||
(runner.has('s') || runner.has('S'))))
|
||||
{
|
||||
relmap.reset(new spot::ltl::relabeling_map);
|
||||
f = spot::ltl::relabel(f, spot::ltl::Pnn, relmap.get());
|
||||
relmap.reset(new spot::relabeling_map);
|
||||
f = spot::relabel(f, spot::Pnn, relmap.get());
|
||||
}
|
||||
|
||||
static unsigned round = 1;
|
||||
|
|
|
|||
|
|
@ -251,7 +251,7 @@ static int bsize_min = -1;
|
|||
static int bsize_max = -1;
|
||||
enum relabeling_mode { NoRelabeling = 0, ApRelabeling, BseRelabeling };
|
||||
static relabeling_mode relabeling = NoRelabeling;
|
||||
static spot::ltl::relabeling_style style = spot::ltl::Abc;
|
||||
static spot::relabeling_style style = spot::Abc;
|
||||
static bool remove_x = false;
|
||||
static bool stutter_insensitive = false;
|
||||
static bool ap = false;
|
||||
|
|
@ -262,16 +262,16 @@ static spot::exclusive_ap excl_ap;
|
|||
static std::unique_ptr<output_file> output_define = nullptr;
|
||||
static std::string unabbreviate;
|
||||
|
||||
static spot::ltl::formula implied_by = nullptr;
|
||||
static spot::ltl::formula imply = nullptr;
|
||||
static spot::ltl::formula equivalent_to = nullptr;
|
||||
static spot::formula implied_by = nullptr;
|
||||
static spot::formula imply = nullptr;
|
||||
static spot::formula equivalent_to = nullptr;
|
||||
|
||||
static spot::ltl::formula
|
||||
static spot::formula
|
||||
parse_formula_arg(const std::string& input)
|
||||
{
|
||||
spot::ltl::parse_error_list pel;
|
||||
spot::ltl::formula f = parse_formula(input, pel);
|
||||
if (spot::ltl::format_parse_errors(std::cerr, input, pel))
|
||||
spot::parse_error_list pel;
|
||||
spot::formula f = parse_formula(input, pel);
|
||||
if (spot::format_parse_errors(std::cerr, input, pel))
|
||||
error(2, 0, "parse error when parsing an argument");
|
||||
return f;
|
||||
}
|
||||
|
|
@ -343,16 +343,16 @@ parse_opt(int key, char* arg, struct argp_state*)
|
|||
break;
|
||||
case OPT_IMPLIED_BY:
|
||||
{
|
||||
spot::ltl::formula i = parse_formula_arg(arg);
|
||||
spot::formula i = parse_formula_arg(arg);
|
||||
// a→c∧b→c ≡ (a∨b)→c
|
||||
implied_by = spot::ltl::formula::Or({implied_by, i});
|
||||
implied_by = spot::formula::Or({implied_by, i});
|
||||
break;
|
||||
}
|
||||
case OPT_IMPLY:
|
||||
{
|
||||
// a→b∧a→c ≡ a→(b∧c)
|
||||
spot::ltl::formula i = parse_formula_arg(arg);
|
||||
imply = spot::ltl::formula::And({imply, i});
|
||||
spot::formula i = parse_formula_arg(arg);
|
||||
imply = spot::formula::And({imply, i});
|
||||
break;
|
||||
}
|
||||
case OPT_LTL:
|
||||
|
|
@ -371,9 +371,9 @@ parse_opt(int key, char* arg, struct argp_state*)
|
|||
case OPT_RELABEL_BOOL:
|
||||
relabeling = (key == OPT_RELABEL_BOOL ? BseRelabeling : ApRelabeling);
|
||||
if (!arg || !strncasecmp(arg, "abc", 6))
|
||||
style = spot::ltl::Abc;
|
||||
style = spot::Abc;
|
||||
else if (!strncasecmp(arg, "pnn", 4))
|
||||
style = spot::ltl::Pnn;
|
||||
style = spot::Pnn;
|
||||
else
|
||||
error(2, 0, "invalid argument for --relabel%s: '%s'",
|
||||
(key == OPT_RELABEL_BOOL ? "-bool" : ""),
|
||||
|
|
@ -404,7 +404,7 @@ parse_opt(int key, char* arg, struct argp_state*)
|
|||
if (arg)
|
||||
unabbreviate += arg;
|
||||
else
|
||||
unabbreviate += spot::ltl::default_unabbrev_string;
|
||||
unabbreviate += spot::default_unabbrev_string;
|
||||
break;
|
||||
case OPT_AP_N:
|
||||
ap = true;
|
||||
|
|
@ -438,18 +438,18 @@ parse_opt(int key, char* arg, struct argp_state*)
|
|||
}
|
||||
|
||||
typedef
|
||||
std::unordered_set<spot::ltl::formula> fset_t;
|
||||
std::unordered_set<spot::formula> fset_t;
|
||||
|
||||
namespace
|
||||
{
|
||||
class ltl_processor: public job_processor
|
||||
{
|
||||
public:
|
||||
spot::ltl::ltl_simplifier& simpl;
|
||||
spot::ltl_simplifier& simpl;
|
||||
fset_t unique_set;
|
||||
spot::ltl::relabeling_map relmap;
|
||||
spot::relabeling_map relmap;
|
||||
|
||||
ltl_processor(spot::ltl::ltl_simplifier& simpl)
|
||||
ltl_processor(spot::ltl_simplifier& simpl)
|
||||
: simpl(simpl)
|
||||
{
|
||||
}
|
||||
|
|
@ -458,8 +458,8 @@ namespace
|
|||
process_string(const std::string& input,
|
||||
const char* filename = nullptr, int linenum = 0)
|
||||
{
|
||||
spot::ltl::parse_error_list pel;
|
||||
spot::ltl::formula f = parse_formula(input, pel);
|
||||
spot::parse_error_list pel;
|
||||
spot::formula f = parse_formula(input, pel);
|
||||
|
||||
if (!f || pel.size() > 0)
|
||||
{
|
||||
|
|
@ -467,7 +467,7 @@ namespace
|
|||
{
|
||||
if (filename)
|
||||
error_at_line(0, 0, filename, linenum, "parse error:");
|
||||
spot::ltl::format_parse_errors(std::cerr, input, pel);
|
||||
spot::format_parse_errors(std::cerr, input, pel);
|
||||
}
|
||||
|
||||
if (error_style == skip_errors)
|
||||
|
|
@ -489,7 +489,7 @@ namespace
|
|||
}
|
||||
|
||||
int
|
||||
process_formula(spot::ltl::formula f,
|
||||
process_formula(spot::formula f,
|
||||
const char* filename = nullptr, int linenum = 0)
|
||||
{
|
||||
if (opt_max_count >= 0 && match_count >= opt_max_count)
|
||||
|
|
@ -499,14 +499,14 @@ namespace
|
|||
}
|
||||
|
||||
if (negate)
|
||||
f = spot::ltl::formula::Not(f);
|
||||
f = spot::formula::Not(f);
|
||||
|
||||
if (remove_x)
|
||||
{
|
||||
// If simplification are enabled, we do them before and after.
|
||||
if (simplification_level)
|
||||
f = simpl.simplify(f);
|
||||
f = spot::ltl::remove_x(f);
|
||||
f = spot::remove_x(f);
|
||||
}
|
||||
|
||||
if (simplification_level || boolean_to_isop)
|
||||
|
|
@ -520,13 +520,13 @@ namespace
|
|||
case ApRelabeling:
|
||||
{
|
||||
relmap.clear();
|
||||
f = spot::ltl::relabel(f, style, &relmap);
|
||||
f = spot::relabel(f, style, &relmap);
|
||||
break;
|
||||
}
|
||||
case BseRelabeling:
|
||||
{
|
||||
relmap.clear();
|
||||
f = spot::ltl::relabel_bse(f, style, &relmap);
|
||||
f = spot::relabel_bse(f, style, &relmap);
|
||||
break;
|
||||
}
|
||||
case NoRelabeling:
|
||||
|
|
@ -534,7 +534,7 @@ namespace
|
|||
}
|
||||
|
||||
if (!unabbreviate.empty())
|
||||
f = spot::ltl::unabbreviate(f, unabbreviate.c_str());
|
||||
f = spot::unabbreviate(f, unabbreviate.c_str());
|
||||
|
||||
if (!excl_ap.empty())
|
||||
f = excl_ap.constrain(f);
|
||||
|
|
@ -556,14 +556,14 @@ namespace
|
|||
|
||||
if (matched && (size_min > 0 || size_max >= 0))
|
||||
{
|
||||
int l = spot::ltl::length(f);
|
||||
int l = spot::length(f);
|
||||
matched &= (size_min <= 0) || (l >= size_min);
|
||||
matched &= (size_max < 0) || (l <= size_max);
|
||||
}
|
||||
|
||||
if (matched && (bsize_min > 0 || bsize_max >= 0))
|
||||
{
|
||||
int l = spot::ltl::length_boolone(f);
|
||||
int l = spot::length_boolone(f);
|
||||
matched &= (bsize_min <= 0) || (l >= bsize_min);
|
||||
matched &= (bsize_max < 0) || (l <= bsize_max);
|
||||
}
|
||||
|
|
@ -606,7 +606,7 @@ namespace
|
|||
&& output_format != quiet_output)
|
||||
{
|
||||
// Sort the formulas alphabetically.
|
||||
std::map<std::string, spot::ltl::formula> m;
|
||||
std::map<std::string, spot::formula> m;
|
||||
for (auto& p: relmap)
|
||||
m.emplace(str_psl(p.first), p.second);
|
||||
for (auto& p: m)
|
||||
|
|
@ -641,9 +641,9 @@ main(int argc, char** argv)
|
|||
|
||||
if (boolean_to_isop && simplification_level == 0)
|
||||
simplification_level = 1;
|
||||
spot::ltl::ltl_simplifier_options opt(simplification_level);
|
||||
spot::ltl_simplifier_options opt(simplification_level);
|
||||
opt.boolean_to_isop = boolean_to_isop;
|
||||
spot::ltl::ltl_simplifier simpl(opt);
|
||||
spot::ltl_simplifier simpl(opt);
|
||||
|
||||
ltl_processor processor(simpl);
|
||||
if (processor.run())
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ enum {
|
|||
static unsigned mutation_nb = 1;
|
||||
static unsigned max_output = -1U;
|
||||
|
||||
static unsigned opt_all = spot::ltl::Mut_All;
|
||||
static unsigned opt_all = spot::Mut_All;
|
||||
static unsigned mut_opts = 0;
|
||||
static bool opt_sort = false;
|
||||
|
||||
|
|
@ -96,11 +96,11 @@ namespace
|
|||
{
|
||||
public:
|
||||
int
|
||||
process_formula(spot::ltl::formula f, const char* filename = nullptr,
|
||||
process_formula(spot::formula f, const char* filename = nullptr,
|
||||
int linenum = 0)
|
||||
{
|
||||
auto mutations =
|
||||
spot::ltl::mutate(f, mut_opts, max_output, mutation_nb, opt_sort);
|
||||
spot::mutate(f, mut_opts, max_output, mutation_nb, opt_sort);
|
||||
for (auto g: mutations)
|
||||
output_formula_checked(g, filename, linenum);
|
||||
return 0;
|
||||
|
|
@ -121,31 +121,31 @@ parse_opt(int key, char* arg, struct argp_state*)
|
|||
break;
|
||||
case OPT_AP2CONST:
|
||||
opt_all = 0;
|
||||
mut_opts |= spot::ltl::Mut_Ap2Const;
|
||||
mut_opts |= spot::Mut_Ap2Const;
|
||||
break;
|
||||
case OPT_REMOVE_ONE_AP:
|
||||
opt_all = 0;
|
||||
mut_opts |= spot::ltl::Mut_Remove_One_Ap;
|
||||
mut_opts |= spot::Mut_Remove_One_Ap;
|
||||
break;
|
||||
case OPT_REMOVE_MULTOP_OPERANDS:
|
||||
opt_all = 0;
|
||||
mut_opts |= spot::ltl::Mut_Remove_Multop_Operands;
|
||||
mut_opts |= spot::Mut_Remove_Multop_Operands;
|
||||
break;
|
||||
case OPT_REMOVE_OPS:
|
||||
opt_all = 0;
|
||||
mut_opts |= spot::ltl::Mut_Remove_Ops;
|
||||
mut_opts |= spot::Mut_Remove_Ops;
|
||||
break;
|
||||
case OPT_SPLIT_OPS:
|
||||
opt_all = 0;
|
||||
mut_opts |= spot::ltl::Mut_Split_Ops;
|
||||
mut_opts |= spot::Mut_Split_Ops;
|
||||
break;
|
||||
case OPT_REWRITE_OPS:
|
||||
opt_all = 0;
|
||||
mut_opts |= spot::ltl::Mut_Rewrite_Ops;
|
||||
mut_opts |= spot::Mut_Rewrite_Ops;
|
||||
break;
|
||||
case OPT_SIMPLIFY_BOUNDS:
|
||||
opt_all = 0;
|
||||
mut_opts |= spot::ltl::Mut_Simplify_Bounds;
|
||||
mut_opts |= spot::Mut_Simplify_Bounds;
|
||||
break;
|
||||
case OPT_SORT:
|
||||
opt_sort = true;
|
||||
|
|
|
|||
|
|
@ -135,7 +135,7 @@ static const struct argp_child children[] =
|
|||
static const char* opt_acceptance = nullptr;
|
||||
typedef spot::twa_graph::graph_t::edge_storage_t tr_t;
|
||||
typedef std::set<std::vector<tr_t>> unique_aut_t;
|
||||
static spot::ltl::atomic_prop_set aprops;
|
||||
static spot::atomic_prop_set aprops;
|
||||
static range ap_count_given = {-1, -2}; // Must be two different negative val
|
||||
static int opt_seed = 0;
|
||||
static const char* opt_seed_str = "0";
|
||||
|
|
@ -249,10 +249,10 @@ parse_opt(int key, char* arg, struct argp_state* as)
|
|||
ap_count_given = parse_range(arg);
|
||||
// Create the set once if the count is fixed.
|
||||
if (ap_count_given.min == ap_count_given.max)
|
||||
aprops = spot::ltl::create_atomic_prop_set(ap_count_given.min);
|
||||
aprops = spot::create_atomic_prop_set(ap_count_given.min);
|
||||
break;
|
||||
}
|
||||
aprops.insert(spot::ltl::formula::ap(arg));
|
||||
aprops.insert(spot::formula::ap(arg));
|
||||
break;
|
||||
|
||||
default:
|
||||
|
|
@ -329,7 +329,7 @@ main(int argc, char** argv)
|
|||
&& ap_count_given.min != ap_count_given.max)
|
||||
{
|
||||
int c = spot::rrand(ap_count_given.min, ap_count_given.max);
|
||||
aprops = spot::ltl::create_atomic_prop_set(c);
|
||||
aprops = spot::create_atomic_prop_set(c);
|
||||
}
|
||||
|
||||
int size = opt_states.min;
|
||||
|
|
|
|||
|
|
@ -130,7 +130,7 @@ const struct argp_child children[] =
|
|||
{ nullptr, 0, nullptr, 0 }
|
||||
};
|
||||
|
||||
spot::ltl::atomic_prop_set aprops;
|
||||
spot::atomic_prop_set aprops;
|
||||
static int output = OUTPUTLTL;
|
||||
static char* opt_pL = nullptr;
|
||||
static char* opt_pS = nullptr;
|
||||
|
|
@ -209,11 +209,11 @@ parse_opt(int key, char* arg, struct argp_state* as)
|
|||
if (!*endptr && res >= 0) // arg is a number
|
||||
{
|
||||
ap_count_given = true;
|
||||
aprops = spot::ltl::create_atomic_prop_set(res);
|
||||
aprops = spot::create_atomic_prop_set(res);
|
||||
break;
|
||||
}
|
||||
}
|
||||
aprops.insert(spot::ltl::default_environment::instance().require(arg));
|
||||
aprops.insert(spot::default_environment::instance().require(arg));
|
||||
break;
|
||||
default:
|
||||
return ARGP_ERR_UNKNOWN;
|
||||
|
|
@ -241,7 +241,7 @@ main(int argc, char** argv)
|
|||
spot::srand(opt_seed);
|
||||
try
|
||||
{
|
||||
spot::ltl::randltlgenerator rg
|
||||
spot::randltlgenerator rg
|
||||
(aprops,
|
||||
[&] (){
|
||||
spot::option_map opts;
|
||||
|
|
@ -292,7 +292,7 @@ main(int argc, char** argv)
|
|||
while (opt_formulas < 0 || opt_formulas--)
|
||||
{
|
||||
static int count = 0;
|
||||
spot::ltl::formula f = rg.next();
|
||||
spot::formula f = rg.next();
|
||||
if (!f)
|
||||
{
|
||||
error(2, 0, "failed to generate a new unique formula after %d " \
|
||||
|
|
|
|||
|
|
@ -260,7 +260,7 @@ namespace spot
|
|||
}
|
||||
|
||||
|
||||
void kripke_explicit::add_condition(ltl::formula f, std::string on_me)
|
||||
void kripke_explicit::add_condition(formula f, std::string on_me)
|
||||
{
|
||||
add_conditions(formula_to_bdd(f, get_dict(), this), on_me);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -151,7 +151,7 @@ namespace spot
|
|||
///
|
||||
/// \param f the formula to add.
|
||||
/// \param on_me the state where to add.
|
||||
void add_condition(ltl::formula f, std::string on_me);
|
||||
void add_condition(formula f, std::string on_me);
|
||||
|
||||
/// \brief Return map between states and their names.
|
||||
const std::map<const state_kripke*, std::string>&
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ typedef std::map<std::string, bdd> formula_cache;
|
|||
}
|
||||
|
||||
%parse-param {spot::kripke_parse_error_list& error_list}
|
||||
%parse-param {spot::ltl::environment& parse_environment}
|
||||
%parse-param {spot::environment& parse_environment}
|
||||
%parse-param {spot::kripke_explicit_ptr& result}
|
||||
%parse-param {formula_cache& fcache}
|
||||
|
||||
|
|
@ -62,9 +62,9 @@ typedef std::map<std::string, bdd> formula_cache;
|
|||
before parsedecl.hh uses it. */
|
||||
#include "parsedecl.hh"
|
||||
|
||||
using namespace spot::ltl;
|
||||
using namespace spot;
|
||||
#include <iostream>
|
||||
//typedef std::pair<bool, spot::ltl::formula*> pair;
|
||||
//typedef std::pair<bool, spot::formula*> pair;
|
||||
}
|
||||
|
||||
%token <str> STRING UNTERMINATED_STRING IDENT
|
||||
|
|
@ -109,7 +109,7 @@ strident "," condition "," follow_list ";"
|
|||
if (i == fcache.end())
|
||||
{
|
||||
parse_error_list pel;
|
||||
formula f = spot::ltl::parse_infix_boolean(*$3, pel,
|
||||
formula f = spot::parse_infix_boolean(*$3, pel,
|
||||
parse_environment);
|
||||
for (parse_error_list::iterator i = pel.begin();
|
||||
i != pel.end(); ++i)
|
||||
|
|
@ -207,7 +207,7 @@ namespace spot
|
|||
error_list.push_back
|
||||
(kripke_parse_error(spot::location(),
|
||||
std::string("Cannot open file ") + name));
|
||||
return 0;
|
||||
return nullptr;
|
||||
}
|
||||
formula_cache fcache;
|
||||
auto result = make_kripke_explicit(dict);
|
||||
|
|
|
|||
|
|
@ -41,15 +41,15 @@ namespace spot
|
|||
kripke_parse(const std::string& name,
|
||||
kripke_parse_error_list& error_list,
|
||||
const bdd_dict_ptr& dict,
|
||||
ltl::environment& env
|
||||
= ltl::default_environment::instance(),
|
||||
environment& env
|
||||
= default_environment::instance(),
|
||||
bool debug = false);
|
||||
|
||||
|
||||
/// \brief Format diagnostics produced by spot::kripke_parse.
|
||||
/// \param os Where diagnostics should be output.
|
||||
/// \param filename The filename that should appear in the diagnostics.
|
||||
/// \param error_list The error list filled by spot::ltl::parse while
|
||||
/// \param error_list The error list filled by spot::parse while
|
||||
/// parsing \a ltl_string.
|
||||
/// \return \c true if any diagnostic was output.
|
||||
SPOT_API
|
||||
|
|
|
|||
|
|
@ -28,9 +28,6 @@
|
|||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
|
||||
void
|
||||
fix_utf8_locations(const std::string& ltl_string,
|
||||
parse_error_list& error_list)
|
||||
|
|
@ -112,6 +109,4 @@ namespace spot
|
|||
return format_parse_errors_aux(os, ltl_string, error_list);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@
|
|||
%debug
|
||||
%error-verbose
|
||||
%expect 0
|
||||
%lex-param { spot::ltl::parse_error_list& error_list }
|
||||
%lex-param { spot::parse_error_list& error_list }
|
||||
%define api.location.type "spot::location"
|
||||
|
||||
%code requires
|
||||
|
|
@ -41,13 +41,13 @@
|
|||
struct minmax_t { unsigned min, max; };
|
||||
}
|
||||
|
||||
%parse-param {spot::ltl::parse_error_list &error_list}
|
||||
%parse-param {spot::ltl::environment &parse_environment}
|
||||
%parse-param {spot::ltl::formula &result}
|
||||
%parse-param {spot::parse_error_list &error_list}
|
||||
%parse-param {spot::environment &parse_environment}
|
||||
%parse-param {spot::formula &result}
|
||||
%union
|
||||
{
|
||||
std::string* str;
|
||||
const spot::ltl::fnode* ltl;
|
||||
const spot::fnode* ltl;
|
||||
unsigned num;
|
||||
minmax_t minmax;
|
||||
}
|
||||
|
|
@ -57,7 +57,7 @@
|
|||
We mut ensure that YYSTYPE is declared (by the above %union)
|
||||
before parsedecl.hh uses it. */
|
||||
#include "parsedecl.hh"
|
||||
using namespace spot::ltl;
|
||||
using namespace spot;
|
||||
|
||||
#define missing_right_op_msg(op, str) \
|
||||
error_list.emplace_back(op, \
|
||||
|
|
@ -94,10 +94,10 @@ using namespace spot::ltl;
|
|||
static formula
|
||||
try_recursive_parse(const std::string& str,
|
||||
const spot::location& location,
|
||||
spot::ltl::environment& env,
|
||||
spot::environment& env,
|
||||
bool debug,
|
||||
parser_type type,
|
||||
spot::ltl::parse_error_list& error_list)
|
||||
spot::parse_error_list& error_list)
|
||||
{
|
||||
// We want to parse a U (b U c) as two until operators applied
|
||||
// to the atomic propositions a, b, and c. We also want to
|
||||
|
|
@ -120,18 +120,18 @@ using namespace spot::ltl;
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
spot::ltl::parse_error_list suberror;
|
||||
spot::parse_error_list suberror;
|
||||
formula f;
|
||||
switch (type)
|
||||
{
|
||||
case parser_sere:
|
||||
f = spot::ltl::parse_infix_sere(str, suberror, env, debug, true);
|
||||
f = spot::parse_infix_sere(str, suberror, env, debug, true);
|
||||
break;
|
||||
case parser_bool:
|
||||
f = spot::ltl::parse_infix_boolean(str, suberror, env, debug, true);
|
||||
f = spot::parse_infix_boolean(str, suberror, env, debug, true);
|
||||
break;
|
||||
case parser_ltl:
|
||||
f = spot::ltl::parse_infix_psl(str, suberror, env, debug, true);
|
||||
f = spot::parse_infix_psl(str, suberror, env, debug, true);
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
@ -237,8 +237,8 @@ using namespace spot::ltl;
|
|||
%destructor { $$->destroy(); } <ltl>
|
||||
|
||||
%printer { debug_stream() << *$$; } <str>
|
||||
%printer { spot::ltl::print_psl(debug_stream(), formula($$)); } <ltl>
|
||||
%printer { spot::ltl::print_sere(debug_stream(), formula($$)); } sere bracedsere
|
||||
%printer { print_psl(debug_stream(), formula($$)); } <ltl>
|
||||
%printer { print_sere(debug_stream(), formula($$)); } sere bracedsere
|
||||
%printer { debug_stream() << $$; } <num>
|
||||
%printer { debug_stream() << $$.min << ".." << $$.max; } <minmax>
|
||||
|
||||
|
|
@ -992,8 +992,6 @@ ltlyy::parser::error(const location_type& location, const std::string& message)
|
|||
}
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
formula
|
||||
parse_infix_psl(const std::string& ltl_string,
|
||||
|
|
@ -1081,8 +1079,6 @@ namespace spot
|
|||
}
|
||||
return f;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
// Local Variables:
|
||||
|
|
|
|||
|
|
@ -99,7 +99,7 @@ eol2 (\n\r)+|(\r\n)+
|
|||
<<EOF>> {
|
||||
BEGIN(orig_cond);
|
||||
error_list.push_back(
|
||||
spot::ltl::one_parse_error(*yylloc,
|
||||
spot::one_parse_error(*yylloc,
|
||||
"unclosed comment"));
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -141,7 +141,7 @@ eol2 (\n\r)+|(\r\n)+
|
|||
unput(')');
|
||||
if (!missing_parent)
|
||||
error_list.push_back(
|
||||
spot::ltl::one_parse_error(*yylloc,
|
||||
spot::one_parse_error(*yylloc,
|
||||
"missing closing parenthese"));
|
||||
missing_parent = true;
|
||||
}
|
||||
|
|
@ -195,7 +195,7 @@ eol2 (\n\r)+|(\r\n)+
|
|||
unput(')');
|
||||
if (!missing_parent)
|
||||
error_list.push_back(
|
||||
spot::ltl::one_parse_error(*yylloc,
|
||||
spot::one_parse_error(*yylloc,
|
||||
"missing closing brace"));
|
||||
missing_parent = true;
|
||||
}
|
||||
|
|
@ -238,7 +238,7 @@ eol2 (\n\r)+|(\r\n)+
|
|||
if (errno || yylval->num != n)
|
||||
{
|
||||
error_list.push_back(
|
||||
spot::ltl::one_parse_error(*yylloc,
|
||||
spot::one_parse_error(*yylloc,
|
||||
"value too large ignored"));
|
||||
// Skip this number and read next token
|
||||
yylloc->step();
|
||||
|
|
@ -347,7 +347,7 @@ eol2 (\n\r)+|(\r\n)+
|
|||
[^\\\"\n\r]+ s.append(yytext, yyleng);
|
||||
<<EOF>> {
|
||||
error_list.push_back(
|
||||
spot::ltl::one_parse_error(*yylloc,
|
||||
spot::one_parse_error(*yylloc,
|
||||
"unclosed string"));
|
||||
BEGIN(orig_cond);
|
||||
yylval->str = new std::string(s);
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
# define YY_DECL \
|
||||
int ltlyylex (ltlyy::parser::semantic_type *yylval, \
|
||||
spot::location *yylloc, \
|
||||
spot::ltl::parse_error_list& error_list)
|
||||
spot::parse_error_list& error_list)
|
||||
YY_DECL;
|
||||
|
||||
void flex_set_buffer(const std::string& buf, int start_tok, bool lenient);
|
||||
|
|
|
|||
|
|
@ -31,8 +31,6 @@
|
|||
#include <iosfwd>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
/// \addtogroup ltl_io
|
||||
/// @{
|
||||
|
|
@ -161,18 +159,18 @@ namespace spot
|
|||
bool debug = false,
|
||||
bool lenient = false);
|
||||
|
||||
/// \brief Format diagnostics produced by spot::ltl::parse
|
||||
/// or spot::ltl::ratexp
|
||||
/// \brief Format diagnostics produced by spot::parse
|
||||
/// or spot::ratexp
|
||||
///
|
||||
/// If the string is utf8 encoded, spot::ltl::fix_utf8_locations()
|
||||
/// If the string is utf8 encoded, spot::fix_utf8_locations()
|
||||
/// will be used to report correct utf8 locations (assuming the
|
||||
/// output is utf8 aware). Nonetheless, the supplied \a
|
||||
/// error_list will not be modified.
|
||||
///
|
||||
/// \param os Where diagnostics should be output.
|
||||
/// \param input_string The string that were parsed.
|
||||
/// \param error_list The error list filled by spot::ltl::parse
|
||||
/// or spot::ltl::parse_sere while parsing \a input_string.
|
||||
/// \param error_list The error list filled by spot::parse
|
||||
/// or spot::parse_sere while parsing \a input_string.
|
||||
/// \return \c true iff any diagnostic was output.
|
||||
SPOT_API
|
||||
bool format_parse_errors(std::ostream& os,
|
||||
|
|
@ -194,13 +192,13 @@ namespace spot
|
|||
/// valid utf8.
|
||||
///
|
||||
/// You should NOT call this function before calling
|
||||
/// spot::ltl::format_parse_errors() because it is already called
|
||||
/// spot::format_parse_errors() because it is already called
|
||||
/// inside if needed. You may need this function only if you want
|
||||
/// to write your own error reporting code.
|
||||
///
|
||||
/// \param input_string The string that were parsed.
|
||||
/// \param error_list The error list filled by spot::ltl::parse
|
||||
/// or spot::ltl::parse_sere while parsing \a input_string.
|
||||
/// \param error_list The error list filled by spot::parse
|
||||
/// or spot::parse_sere while parsing \a input_string.
|
||||
SPOT_API
|
||||
void
|
||||
fix_utf8_locations(const std::string& input_string,
|
||||
|
|
@ -208,4 +206,3 @@ namespace spot
|
|||
|
||||
/// @}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@
|
|||
typedef std::map<int, bdd> map_t;
|
||||
|
||||
/* Cache parsed formulae. Labels on arcs are frequently identical
|
||||
and it would be a waste of time to parse them to ltl::formula
|
||||
and it would be a waste of time to parse them to formula
|
||||
over and over, and to register all their atomic_propositions in
|
||||
the bdd_dict. Keep the bdd result around so we can reuse
|
||||
it. */
|
||||
|
|
@ -71,7 +71,7 @@
|
|||
spot::location used_loc;
|
||||
};
|
||||
spot::parsed_aut_ptr h;
|
||||
spot::ltl::environment* env;
|
||||
spot::environment* env;
|
||||
formula_cache fcache;
|
||||
named_tgba_t* namer = nullptr;
|
||||
spot::acc_mapper_int* acc_mapper = nullptr;
|
||||
|
|
@ -1403,8 +1403,8 @@ nc-formula: nc-formula-or-ident
|
|||
auto i = res.fcache.find(*$1);
|
||||
if (i == res.fcache.end())
|
||||
{
|
||||
spot::ltl::parse_error_list pel;
|
||||
auto f = spot::ltl::parse_infix_boolean(*$1, pel, *res.env,
|
||||
spot::parse_error_list pel;
|
||||
auto f = spot::parse_infix_boolean(*$1, pel, *res.env,
|
||||
debug_level(), true);
|
||||
for (auto& j: pel)
|
||||
{
|
||||
|
|
@ -1578,8 +1578,8 @@ lbtt-acc: { $$ = 0U; }
|
|||
}
|
||||
lbtt-guard: STRING
|
||||
{
|
||||
spot::ltl::parse_error_list pel;
|
||||
auto f = spot::ltl::parse_prefix_ltl(*$1, pel, *res.env);
|
||||
spot::parse_error_list pel;
|
||||
auto f = spot::parse_prefix_ltl(*$1, pel, *res.env);
|
||||
if (!f || !pel.empty())
|
||||
{
|
||||
std::string s = "failed to parse guard: ";
|
||||
|
|
@ -1884,7 +1884,7 @@ namespace spot
|
|||
parsed_aut_ptr
|
||||
automaton_stream_parser::parse(parse_aut_error_list& error_list,
|
||||
const bdd_dict_ptr& dict,
|
||||
ltl::environment& env,
|
||||
environment& env,
|
||||
bool debug)
|
||||
{
|
||||
restart:
|
||||
|
|
@ -1927,7 +1927,7 @@ namespace spot
|
|||
|
||||
twa_graph_ptr
|
||||
automaton_stream_parser::parse_strict(const bdd_dict_ptr& dict,
|
||||
ltl::environment& env,
|
||||
environment& env,
|
||||
bool debug)
|
||||
{
|
||||
parse_aut_error_list pel;
|
||||
|
|
|
|||
|
|
@ -79,13 +79,13 @@ namespace spot
|
|||
~automaton_stream_parser();
|
||||
parsed_aut_ptr parse(parse_aut_error_list& error_list,
|
||||
const bdd_dict_ptr& dict,
|
||||
ltl::environment& env =
|
||||
ltl::default_environment::instance(),
|
||||
environment& env =
|
||||
default_environment::instance(),
|
||||
bool debug = false);
|
||||
// Raises a parse_error on any syntax error
|
||||
twa_graph_ptr parse_strict(const bdd_dict_ptr& dict,
|
||||
ltl::environment& env =
|
||||
ltl::default_environment::instance(),
|
||||
environment& env =
|
||||
default_environment::instance(),
|
||||
bool debug = false);
|
||||
};
|
||||
|
||||
|
|
@ -120,7 +120,7 @@ namespace spot
|
|||
parse_aut(const std::string& filename,
|
||||
parse_aut_error_list& error_list,
|
||||
const bdd_dict_ptr& dict,
|
||||
ltl::environment& env = ltl::default_environment::instance(),
|
||||
environment& env = default_environment::instance(),
|
||||
bool debug = false)
|
||||
{
|
||||
try
|
||||
|
|
@ -138,7 +138,7 @@ namespace spot
|
|||
/// \brief Format diagnostics produced by spot::parse_aut.
|
||||
/// \param os Where diagnostics should be output.
|
||||
/// \param filename The filename that should appear in the diagnostics.
|
||||
/// \param error_list The error list filled by spot::ltl::parse while
|
||||
/// \param error_list The error list filled by spot::parse while
|
||||
/// parsing \a ltl_string.
|
||||
/// \return \c true iff any diagnostic was output.
|
||||
SPOT_API bool
|
||||
|
|
|
|||
|
|
@ -60,13 +60,13 @@ main(int argc, char** argv)
|
|||
if (s.empty() || s[0] == '#') // Skip comments
|
||||
continue;
|
||||
|
||||
spot::ltl::parse_error_list pe;
|
||||
auto fpos = spot::ltl::parse_infix_psl(s, pe);
|
||||
spot::parse_error_list pe;
|
||||
auto fpos = spot::parse_infix_psl(s, pe);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, s, pe))
|
||||
if (spot::format_parse_errors(std::cerr, s, pe))
|
||||
return 2;
|
||||
|
||||
auto fneg = spot::ltl::formula::Not(fpos);
|
||||
auto fneg = spot::formula::Not(fpos);
|
||||
|
||||
{
|
||||
auto apos = scc_filter(ltl_to_tgba_fm(fpos, d));
|
||||
|
|
@ -104,6 +104,6 @@ main(int argc, char** argv)
|
|||
}
|
||||
}
|
||||
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -83,10 +83,10 @@ main(int argc, char** argv)
|
|||
if (s.empty() || s[0] == '#') // Skip comments
|
||||
continue;
|
||||
|
||||
spot::ltl::parse_error_list pe;
|
||||
auto f = spot::ltl::parse_infix_psl(s, pe);
|
||||
spot::parse_error_list pe;
|
||||
auto f = spot::parse_infix_psl(s, pe);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, s, pe))
|
||||
if (spot::format_parse_errors(std::cerr, s, pe))
|
||||
return 2;
|
||||
|
||||
|
||||
|
|
@ -220,6 +220,6 @@ main(int argc, char** argv)
|
|||
}
|
||||
}
|
||||
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -119,7 +119,7 @@ int main(int argc, char* argv[])
|
|||
auto dict = spot::make_bdd_dict();
|
||||
if (print_automaton || print_safra)
|
||||
{
|
||||
spot::ltl::environment& env(spot::ltl::default_environment::instance());
|
||||
spot::environment& env(spot::default_environment::instance());
|
||||
spot::parse_aut_error_list pel;
|
||||
auto h = spot::parse_aut(file, pel, dict, env);
|
||||
if (spot::format_parse_aut_errors(std::cerr, file, pel))
|
||||
|
|
@ -147,10 +147,10 @@ int main(int argc, char* argv[])
|
|||
}
|
||||
else if (print_formula)
|
||||
{
|
||||
spot::ltl::parse_error_list p1;
|
||||
auto f1 = spot::ltl::parse_infix_psl(file, p1);
|
||||
spot::parse_error_list p1;
|
||||
auto f1 = spot::parse_infix_psl(file, p1);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, file, p1))
|
||||
if (spot::format_parse_errors(std::cerr, file, p1))
|
||||
return 2;
|
||||
|
||||
auto a = spot::ltl_to_tgba_fm(f1, dict);
|
||||
|
|
@ -162,14 +162,14 @@ int main(int argc, char* argv[])
|
|||
else if (stats)
|
||||
{
|
||||
spot::twa_graph_ptr a;
|
||||
spot::ltl::formula f1 = nullptr;
|
||||
spot::formula f1 = nullptr;
|
||||
|
||||
if (formula)
|
||||
{
|
||||
spot::ltl::parse_error_list p1;
|
||||
f1 = spot::ltl::parse_infix_psl(file, p1);
|
||||
spot::parse_error_list p1;
|
||||
f1 = spot::parse_infix_psl(file, p1);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, file, p1))
|
||||
if (spot::format_parse_errors(std::cerr, file, p1))
|
||||
return 2;
|
||||
|
||||
a = spot::ltl_to_tgba_fm(f1, dict);
|
||||
|
|
@ -177,7 +177,7 @@ int main(int argc, char* argv[])
|
|||
else
|
||||
{
|
||||
spot::parse_aut_error_list pel;
|
||||
spot::ltl::environment& env(spot::ltl::default_environment::instance());
|
||||
spot::environment& env(spot::default_environment::instance());
|
||||
auto h = spot::parse_aut(file, pel, dict, env);
|
||||
if (spot::format_parse_aut_errors(std::cerr, file, pel))
|
||||
return 2;
|
||||
|
|
@ -209,7 +209,7 @@ int main(int argc, char* argv[])
|
|||
|
||||
if (formula)
|
||||
{
|
||||
auto a2 = spot::ltl_to_tgba_fm(spot::ltl::formula::Not(f1), dict);
|
||||
auto a2 = spot::ltl_to_tgba_fm(spot::formula::Not(f1), dict);
|
||||
spot::tgba_statistics a_size = spot::stats_reachable(a2);
|
||||
std::cout << "Not Formula: "
|
||||
<< a_size.states << ", "
|
||||
|
|
@ -220,14 +220,14 @@ int main(int argc, char* argv[])
|
|||
}
|
||||
else
|
||||
{
|
||||
spot::ltl::parse_error_list p1;
|
||||
auto f1 = spot::ltl::parse_infix_psl(file, p1);
|
||||
spot::parse_error_list p1;
|
||||
auto f1 = spot::parse_infix_psl(file, p1);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, file, p1))
|
||||
if (spot::format_parse_errors(std::cerr, file, p1))
|
||||
return 2;
|
||||
|
||||
auto Af = spot::ltl_to_tgba_fm(f1, dict);
|
||||
auto nf1 = spot::ltl::formula::Not(f1);
|
||||
auto nf1 = spot::formula::Not(f1);
|
||||
auto Anf = spot::ltl_to_tgba_fm(nf1, dict);
|
||||
auto nAf = spot::make_safra_complement(Af);
|
||||
auto nAnf = spot::make_safra_complement(Anf);
|
||||
|
|
|
|||
|
|
@ -58,9 +58,9 @@ main(int argc, char **argv)
|
|||
std::getline(ss, form, ',');
|
||||
ss >> expected;
|
||||
|
||||
spot::ltl::parse_error_list p1;
|
||||
auto f1 = spot::ltl::parse_infix_sere(form, p1);
|
||||
if (spot::ltl::format_parse_errors(std::cerr, form, p1))
|
||||
spot::parse_error_list p1;
|
||||
auto f1 = spot::parse_infix_sere(form, p1);
|
||||
if (spot::format_parse_errors(std::cerr, form, p1))
|
||||
return 2;
|
||||
|
||||
bool b = f1.accepts_eword();
|
||||
|
|
@ -73,6 +73,6 @@ main(int argc, char **argv)
|
|||
}
|
||||
}
|
||||
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -89,9 +89,9 @@ main(int argc, char** argv)
|
|||
|
||||
int runs = atoi(tokens[0].c_str());
|
||||
|
||||
spot::ltl::parse_error_list pe;
|
||||
auto f = spot::ltl::parse_infix_psl(tokens[1], pe);
|
||||
if (spot::ltl::format_parse_errors(std::cerr, tokens[1], pe))
|
||||
spot::parse_error_list pe;
|
||||
auto f = spot::parse_infix_psl(tokens[1], pe);
|
||||
if (spot::format_parse_errors(std::cerr, tokens[1], pe))
|
||||
return 2;
|
||||
|
||||
auto d = spot::make_bdd_dict();
|
||||
|
|
@ -199,6 +199,6 @@ main(int argc, char** argv)
|
|||
}
|
||||
}
|
||||
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -95,47 +95,47 @@ main(int argc, char** argv)
|
|||
return 2;
|
||||
}
|
||||
|
||||
spot::ltl::parse_error_list p2;
|
||||
auto f2 = spot::ltl::parse_infix_psl(formulas[size - 1], p2);
|
||||
spot::parse_error_list p2;
|
||||
auto f2 = spot::parse_infix_psl(formulas[size - 1], p2);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, formulas[size - 1], p2))
|
||||
if (spot::format_parse_errors(std::cerr, formulas[size - 1], p2))
|
||||
return 2;
|
||||
|
||||
for (unsigned n = 0; n < size - 1; ++n)
|
||||
{
|
||||
|
||||
spot::ltl::parse_error_list p1;
|
||||
auto f1 = spot::ltl::parse_infix_psl(formulas[n], p1);
|
||||
spot::parse_error_list p1;
|
||||
auto f1 = spot::parse_infix_psl(formulas[n], p1);
|
||||
|
||||
if (check_first &&
|
||||
spot::ltl::format_parse_errors(std::cerr, formulas[n], p1))
|
||||
spot::format_parse_errors(std::cerr, formulas[n], p1))
|
||||
return 2;
|
||||
|
||||
int exit_code = 0;
|
||||
|
||||
{
|
||||
#if defined UNABBREV || defined NENOFORM
|
||||
spot::ltl::formula tmp;
|
||||
spot::formula tmp;
|
||||
#endif
|
||||
#ifdef UNABBREV
|
||||
tmp = f1;
|
||||
f1 = spot::ltl::unabbreviate(f1, UNABBREV);
|
||||
f1 = spot::unabbreviate(f1, UNABBREV);
|
||||
f1.dump(std::cout) << std::endl;
|
||||
#endif
|
||||
#ifdef NENOFORM
|
||||
tmp = f1;
|
||||
f1 = spot::ltl::negative_normal_form(f1);
|
||||
f1 = spot::negative_normal_form(f1);
|
||||
f1.dump(std::cout) << std::endl;
|
||||
#endif
|
||||
#ifdef REDUC
|
||||
spot::ltl::ltl_simplifier_options opt(true, true, true,
|
||||
spot::ltl_simplifier_options opt(true, true, true,
|
||||
false, false);
|
||||
# ifdef EVENT_UNIV
|
||||
opt.favor_event_univ = true;
|
||||
# endif
|
||||
spot::ltl::ltl_simplifier simp(opt);
|
||||
spot::ltl_simplifier simp(opt);
|
||||
{
|
||||
spot::ltl::formula tmp;
|
||||
spot::formula tmp;
|
||||
tmp = f1;
|
||||
f1 = simp.simplify(f1);
|
||||
|
||||
|
|
@ -143,18 +143,18 @@ main(int argc, char** argv)
|
|||
{
|
||||
std::cerr
|
||||
<< "Source and simplified formulae are not equivalent!\n";
|
||||
spot::ltl::print_psl(std::cerr << "Simplified: ", f1) << '\n';
|
||||
spot::print_psl(std::cerr << "Simplified: ", f1) << '\n';
|
||||
exit_code = 1;
|
||||
}
|
||||
}
|
||||
f1.dump(std::cout) << std::endl;
|
||||
#endif
|
||||
#ifdef REDUC_TAU
|
||||
spot::ltl::ltl_simplifier_options opt(false, false, false,
|
||||
spot::ltl_simplifier_options opt(false, false, false,
|
||||
true, false);
|
||||
spot::ltl::ltl_simplifier simp(opt);
|
||||
spot::ltl_simplifier simp(opt);
|
||||
{
|
||||
spot::ltl::formula tmp;
|
||||
spot::formula tmp;
|
||||
tmp = f1;
|
||||
f1 = simp.simplify(f1);
|
||||
|
||||
|
|
@ -162,18 +162,18 @@ main(int argc, char** argv)
|
|||
{
|
||||
std::cerr
|
||||
<< "Source and simplified formulae are not equivalent!\n";
|
||||
spot::ltl::print_psl(std::cerr << "Simplified: ", f1) << '\n';
|
||||
spot::print_psl(std::cerr << "Simplified: ", f1) << '\n';
|
||||
exit_code = 1;
|
||||
}
|
||||
}
|
||||
f1.dump(std::cout) << std::endl;
|
||||
#endif
|
||||
#ifdef REDUC_TAUSTR
|
||||
spot::ltl::ltl_simplifier_options opt(false, false, false,
|
||||
spot::ltl_simplifier_options opt(false, false, false,
|
||||
true, true);
|
||||
spot::ltl::ltl_simplifier simp(opt);
|
||||
spot::ltl_simplifier simp(opt);
|
||||
{
|
||||
spot::ltl::formula tmp;
|
||||
spot::formula tmp;
|
||||
tmp = f1;
|
||||
f1 = simp.simplify(f1);
|
||||
|
||||
|
|
@ -181,7 +181,7 @@ main(int argc, char** argv)
|
|||
{
|
||||
std::cerr
|
||||
<< "Source and simplified formulae are not equivalent!\n";
|
||||
spot::ltl::print_psl(std::cerr << "Simplified: ", f1) << '\n';
|
||||
spot::print_psl(std::cerr << "Simplified: ", f1) << '\n';
|
||||
exit_code = 1;
|
||||
}
|
||||
}
|
||||
|
|
@ -191,7 +191,7 @@ main(int argc, char** argv)
|
|||
exit_code |= f1 != f2;
|
||||
|
||||
#if (!defined(REDUC) && !defined(REDUC_TAU) && !defined(REDUC_TAUSTR))
|
||||
spot::ltl::ltl_simplifier simp;
|
||||
spot::ltl_simplifier simp;
|
||||
#endif
|
||||
|
||||
if (!simp.are_equivalent(f1, f2))
|
||||
|
|
@ -215,6 +215,6 @@ main(int argc, char** argv)
|
|||
}
|
||||
}
|
||||
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -342,7 +342,7 @@ checked_main(int argc, char** argv)
|
|||
bool nra2nba = false;
|
||||
bool scc_filter = false;
|
||||
bool simpltl = false;
|
||||
spot::ltl::ltl_simplifier_options redopt(false, false, false, false,
|
||||
spot::ltl_simplifier_options redopt(false, false, false, false,
|
||||
false, false, false);
|
||||
bool simpcache_stats = false;
|
||||
bool scc_filter_all = false;
|
||||
|
|
@ -363,8 +363,8 @@ checked_main(int argc, char** argv)
|
|||
bool opt_stutterize = false;
|
||||
const char* opt_never = nullptr;
|
||||
const char* hoa_opt = nullptr;
|
||||
auto& env = spot::ltl::default_environment::instance();
|
||||
spot::ltl::atomic_prop_set* unobservables = nullptr;
|
||||
auto& env = spot::default_environment::instance();
|
||||
spot::atomic_prop_set* unobservables = nullptr;
|
||||
spot::twa_ptr system_aut = nullptr;
|
||||
auto dict = spot::make_bdd_dict();
|
||||
spot::timer_map tm;
|
||||
|
|
@ -790,7 +790,7 @@ checked_main(int argc, char** argv)
|
|||
}
|
||||
else if (!strncmp(argv[formula_index], "-U", 2))
|
||||
{
|
||||
unobservables = new spot::ltl::atomic_prop_set;
|
||||
unobservables = new spot::atomic_prop_set;
|
||||
translation = TransFM;
|
||||
// Parse -U's argument.
|
||||
const char* tok = strtok(argv[formula_index] + 2, ", \t;");
|
||||
|
|
@ -923,7 +923,7 @@ checked_main(int argc, char** argv)
|
|||
input = argv[formula_index];
|
||||
}
|
||||
|
||||
spot::ltl::formula f = nullptr;
|
||||
spot::formula f = nullptr;
|
||||
if (!from_file) // Reading a formula, not reading an automaton from a file.
|
||||
{
|
||||
switch (translation)
|
||||
|
|
@ -932,11 +932,11 @@ checked_main(int argc, char** argv)
|
|||
case TransTAA:
|
||||
case TransCompo:
|
||||
{
|
||||
spot::ltl::parse_error_list pel;
|
||||
spot::parse_error_list pel;
|
||||
tm.start("parsing formula");
|
||||
f = spot::ltl::parse_infix_psl(input, pel, env, debug_opt);
|
||||
f = spot::parse_infix_psl(input, pel, env, debug_opt);
|
||||
tm.stop("parsing formula");
|
||||
exit_code = spot::ltl::format_parse_errors(std::cerr, input, pel);
|
||||
exit_code = spot::format_parse_errors(std::cerr, input, pel);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
@ -964,14 +964,14 @@ checked_main(int argc, char** argv)
|
|||
}
|
||||
else
|
||||
{
|
||||
spot::ltl::ltl_simplifier* simp = nullptr;
|
||||
spot::ltl_simplifier* simp = nullptr;
|
||||
if (simpltl)
|
||||
simp = new spot::ltl::ltl_simplifier(redopt, dict);
|
||||
simp = new spot::ltl_simplifier(redopt, dict);
|
||||
|
||||
if (simp)
|
||||
{
|
||||
tm.start("reducing formula");
|
||||
spot::ltl::formula t = simp->simplify(f);
|
||||
spot::formula t = simp->simplify(f);
|
||||
tm.stop("reducing formula");
|
||||
f = t;
|
||||
if (display_reduced_form)
|
||||
|
|
@ -1659,6 +1659,6 @@ int
|
|||
main(int argc, char** argv)
|
||||
{
|
||||
int exit_code = checked_main(argc, argv);
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return exit_code;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -58,13 +58,13 @@ main(int argc, char **argv)
|
|||
std::getline(ss, form, ',');
|
||||
std::getline(ss, expected);
|
||||
|
||||
spot::ltl::parse_error_list p1;
|
||||
auto f1 = spot::ltl::parse_infix_psl(form, p1);
|
||||
if (spot::ltl::format_parse_errors(std::cerr, form, p1))
|
||||
spot::parse_error_list p1;
|
||||
auto f1 = spot::parse_infix_psl(form, p1);
|
||||
if (spot::format_parse_errors(std::cerr, form, p1))
|
||||
return 2;
|
||||
|
||||
std::ostringstream so;
|
||||
spot::ltl::print_formula_props(so, f1, true);
|
||||
spot::print_formula_props(so, f1, true);
|
||||
auto sost = so.str();
|
||||
std::cout << form << ',' << sost << '\n';
|
||||
if (sost != expected)
|
||||
|
|
@ -74,6 +74,6 @@ main(int argc, char **argv)
|
|||
return 2;
|
||||
}
|
||||
}
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,18 +45,18 @@ main(int argc, char **argv)
|
|||
}
|
||||
|
||||
{
|
||||
spot::ltl::parse_error_list p1;
|
||||
auto f1 = spot::ltl::parse_infix_psl(argv[1], p1);
|
||||
spot::parse_error_list p1;
|
||||
auto f1 = spot::parse_infix_psl(argv[1], p1);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, argv[1], p1))
|
||||
if (spot::format_parse_errors(std::cerr, argv[1], p1))
|
||||
return 2;
|
||||
|
||||
if (boolone)
|
||||
std::cout << spot::ltl::length_boolone(f1) << std::endl;
|
||||
std::cout << spot::length_boolone(f1) << std::endl;
|
||||
else
|
||||
std::cout << spot::ltl::length(f1) << std::endl;
|
||||
std::cout << spot::length(f1) << std::endl;
|
||||
}
|
||||
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,18 +44,18 @@ main(int argc, char** argv)
|
|||
syntax(argv[0]);
|
||||
|
||||
{
|
||||
spot::ltl::environment& env(spot::ltl::default_environment::instance());
|
||||
spot::environment& env(spot::default_environment::instance());
|
||||
|
||||
spot::ltl::parse_error_list pel1;
|
||||
auto f1 = spot::ltl::parse_infix_psl(argv[1], pel1, env);
|
||||
spot::parse_error_list pel1;
|
||||
auto f1 = spot::parse_infix_psl(argv[1], pel1, env);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, argv[1], pel1))
|
||||
if (spot::format_parse_errors(std::cerr, argv[1], pel1))
|
||||
return 2;
|
||||
|
||||
spot::ltl::parse_error_list pel2;
|
||||
auto f2 = spot::ltl::parse_infix_psl(argv[2], pel2, env);
|
||||
spot::parse_error_list pel2;
|
||||
auto f2 = spot::parse_infix_psl(argv[2], pel2, env);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, argv[2], pel2))
|
||||
if (spot::format_parse_errors(std::cerr, argv[2], pel2))
|
||||
return 2;
|
||||
|
||||
auto dict = spot::make_bdd_dict();
|
||||
|
|
@ -65,6 +65,6 @@ main(int argc, char** argv)
|
|||
spot::print_dot(std::cout, product(a1, a2));
|
||||
}
|
||||
}
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return exit_code;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,29 +38,29 @@ main(int argc, char **argv)
|
|||
syntax(argv[0]);
|
||||
|
||||
{
|
||||
spot::ltl::parse_error_list p1;
|
||||
auto f1 = spot::ltl::parse_infix_psl(argv[1], p1);
|
||||
spot::parse_error_list p1;
|
||||
auto f1 = spot::parse_infix_psl(argv[1], p1);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, argv[1], p1))
|
||||
if (spot::format_parse_errors(std::cerr, argv[1], p1))
|
||||
return 2;
|
||||
|
||||
spot::ltl::relabeling_map* m = new spot::ltl::relabeling_map;
|
||||
auto f2 = spot::ltl::relabel_bse(f1, spot::ltl::Pnn, m);
|
||||
spot::ltl::print_psl(std::cout, f2) << '\n';
|
||||
spot::relabeling_map* m = new spot::relabeling_map;
|
||||
auto f2 = spot::relabel_bse(f1, spot::Pnn, m);
|
||||
spot::print_psl(std::cout, f2) << '\n';
|
||||
|
||||
|
||||
typedef std::map<std::string, std::string> map_t;
|
||||
map_t sorted_map;
|
||||
for (spot::ltl::relabeling_map::const_iterator i = m->begin();
|
||||
for (spot::relabeling_map::const_iterator i = m->begin();
|
||||
i != m->end(); ++i)
|
||||
sorted_map[spot::ltl::str_psl(i->first)] =
|
||||
spot::ltl::str_psl(i->second);
|
||||
sorted_map[spot::str_psl(i->first)] =
|
||||
spot::str_psl(i->second);
|
||||
for (map_t::const_iterator i = sorted_map.begin();
|
||||
i != sorted_map.end(); ++i)
|
||||
std::cout << " " << i->first << " -> "
|
||||
<< i->second << '\n';
|
||||
delete m;
|
||||
}
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@
|
|||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
|
||||
# Check that spot::ltl::parse succeed on valid input, and that
|
||||
# Check that spot::parse succeed on valid input, and that
|
||||
# dump and dotty will work with the resulting trees. Note that
|
||||
# this doesn't check that the tree is correct w.r.t. the formula.
|
||||
|
||||
|
|
|
|||
|
|
@ -42,6 +42,6 @@ int main(int argc, char** argv)
|
|||
kripke_save_reachable(std::cout, k);
|
||||
}
|
||||
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return return_value;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -486,9 +486,9 @@ print_ar_stats(ar_stats_type& ar_stats, const std::string& s)
|
|||
std::cout << std::setiosflags(old);
|
||||
}
|
||||
|
||||
spot::ltl::formula
|
||||
generate_formula(const spot::ltl::random_ltl& rl,
|
||||
spot::ltl::ltl_simplifier& simp,
|
||||
spot::formula
|
||||
generate_formula(const spot::random_ltl& rl,
|
||||
spot::ltl_simplifier& simp,
|
||||
int opt_f, int opt_s,
|
||||
int opt_l = 0, bool opt_u = false)
|
||||
{
|
||||
|
|
@ -498,7 +498,7 @@ generate_formula(const spot::ltl::random_ltl& rl,
|
|||
while (max_tries_u--)
|
||||
{
|
||||
spot::srand(opt_s++);
|
||||
spot::ltl::formula f;
|
||||
spot::formula f;
|
||||
int max_tries_l = 1000;
|
||||
while (max_tries_l--)
|
||||
{
|
||||
|
|
@ -506,12 +506,12 @@ generate_formula(const spot::ltl::random_ltl& rl,
|
|||
if (opt_l)
|
||||
{
|
||||
f = simp.simplify(f);
|
||||
if (spot::ltl::length(f) < opt_l)
|
||||
if (spot::length(f) < opt_l)
|
||||
continue;
|
||||
}
|
||||
else
|
||||
{
|
||||
assert(spot::ltl::length(f) <= opt_f);
|
||||
assert(spot::length(f) <= opt_f);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
@ -522,7 +522,7 @@ generate_formula(const spot::ltl::random_ltl& rl,
|
|||
<< "of size " << opt_l << " or more." << std::endl;
|
||||
return nullptr;
|
||||
}
|
||||
std::string txt = spot::ltl::str_psl(f);
|
||||
std::string txt = spot::str_psl(f);
|
||||
if (!opt_u || unique.insert(txt).second)
|
||||
return f;
|
||||
}
|
||||
|
|
@ -576,12 +576,12 @@ main(int argc, char** argv)
|
|||
|
||||
spot::option_map options;
|
||||
|
||||
auto& env = spot::ltl::default_environment::instance();
|
||||
spot::ltl::atomic_prop_set* ap = new spot::ltl::atomic_prop_set;
|
||||
auto& env = spot::default_environment::instance();
|
||||
spot::atomic_prop_set* ap = new spot::atomic_prop_set;
|
||||
auto dict = spot::make_bdd_dict();
|
||||
|
||||
spot::ltl::ltl_simplifier_options simpopt(true, true, true, true, true);
|
||||
spot::ltl::ltl_simplifier simp(simpopt);
|
||||
spot::ltl_simplifier_options simpopt(true, true, true, true, true);
|
||||
spot::ltl_simplifier simp(simpopt);
|
||||
|
||||
if (argc <= 1)
|
||||
syntax(argv[0]);
|
||||
|
|
@ -788,7 +788,7 @@ main(int argc, char** argv)
|
|||
}
|
||||
}
|
||||
|
||||
spot::ltl::random_ltl rl(ap);
|
||||
spot::random_ltl rl(ap);
|
||||
const char* tok = rl.parse_options(opt_p);
|
||||
if (tok)
|
||||
{
|
||||
|
|
@ -824,7 +824,7 @@ main(int argc, char** argv)
|
|||
spot::timer_map tm_ar;
|
||||
std::set<int> failed_seeds;
|
||||
int init_opt_ec = opt_ec;
|
||||
spot::ltl::atomic_prop_set* apf = new spot::ltl::atomic_prop_set;
|
||||
spot::atomic_prop_set* apf = new spot::atomic_prop_set;
|
||||
|
||||
if (opt_ec)
|
||||
{
|
||||
|
|
@ -847,7 +847,7 @@ main(int argc, char** argv)
|
|||
{
|
||||
if (opt_F)
|
||||
{
|
||||
spot::ltl::formula f =
|
||||
spot::formula f =
|
||||
generate_formula(rl, simp, opt_f, opt_ec_seed, opt_l, opt_u);
|
||||
if (!f)
|
||||
exit(1);
|
||||
|
|
@ -862,15 +862,15 @@ main(int argc, char** argv)
|
|||
break;
|
||||
else if (input == "")
|
||||
break;
|
||||
spot::ltl::parse_error_list pel;
|
||||
auto f = spot::ltl::parse_infix_psl(input, pel, env);
|
||||
if (spot::ltl::format_parse_errors(std::cerr, input, pel))
|
||||
spot::parse_error_list pel;
|
||||
auto f = spot::parse_infix_psl(input, pel, env);
|
||||
if (spot::format_parse_errors(std::cerr, input, pel))
|
||||
{
|
||||
exit_code = 1;
|
||||
break;
|
||||
}
|
||||
formula = spot::ltl_to_tgba_fm(f, dict, true);
|
||||
auto* tmp = spot::ltl::atomic_prop_collect(f);
|
||||
auto* tmp = spot::atomic_prop_collect(f);
|
||||
for (auto i: *tmp)
|
||||
apf->insert(i);
|
||||
delete tmp;
|
||||
|
|
|
|||
|
|
@ -54,18 +54,18 @@ main(int argc, char** argv)
|
|||
}
|
||||
|
||||
{
|
||||
spot::ltl::environment& env(spot::ltl::default_environment::instance());
|
||||
spot::ltl::parse_error_list pel;
|
||||
auto f = spot::ltl::parse_infix_psl(argv[formula_index], pel, env, debug);
|
||||
spot::environment& env(spot::default_environment::instance());
|
||||
spot::parse_error_list pel;
|
||||
auto f = spot::parse_infix_psl(argv[formula_index], pel, env, debug);
|
||||
|
||||
exit_code =
|
||||
spot::ltl::format_parse_errors(std::cerr, argv[formula_index], pel);
|
||||
spot::format_parse_errors(std::cerr, argv[formula_index], pel);
|
||||
|
||||
|
||||
if (f)
|
||||
{
|
||||
#ifdef DOTTY
|
||||
spot::ltl::print_dot_psl(std::cout, f);
|
||||
spot::print_dot_psl(std::cout, f);
|
||||
#else
|
||||
f.dump(std::cout) << std::endl;
|
||||
#endif
|
||||
|
|
@ -76,6 +76,6 @@ main(int argc, char** argv)
|
|||
}
|
||||
|
||||
}
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return exit_code;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ main(int argc, char** argv)
|
|||
bool hidereduc = false;
|
||||
unsigned long sum_before = 0;
|
||||
unsigned long sum_after = 0;
|
||||
spot::ltl::ltl_simplifier_options o(false, false, false, false, false);
|
||||
spot::ltl_simplifier_options o(false, false, false, false, false);
|
||||
|
||||
if (argc < 3)
|
||||
syntax(argv[0]);
|
||||
|
|
@ -147,12 +147,12 @@ main(int argc, char** argv)
|
|||
int exit_code = 0;
|
||||
|
||||
{
|
||||
spot::ltl::ltl_simplifier* simp = new spot::ltl::ltl_simplifier(o);
|
||||
spot::ltl_simplifier* simp = new spot::ltl_simplifier(o);
|
||||
o.reduce_size_strictly = true;
|
||||
spot::ltl::ltl_simplifier* simp_size = new spot::ltl::ltl_simplifier(o);
|
||||
spot::ltl_simplifier* simp_size = new spot::ltl_simplifier(o);
|
||||
|
||||
spot::ltl::formula f1 = nullptr;
|
||||
spot::ltl::formula f2 = nullptr;
|
||||
spot::formula f1 = nullptr;
|
||||
spot::formula f2 = nullptr;
|
||||
|
||||
std::ifstream* fin = nullptr;
|
||||
|
||||
|
|
@ -178,16 +178,16 @@ main(int argc, char** argv)
|
|||
}
|
||||
while (input == "");
|
||||
|
||||
spot::ltl::parse_error_list p1;
|
||||
f1 = spot::ltl::parse_infix_psl(input, p1);
|
||||
if (spot::ltl::format_parse_errors(std::cerr, input, p1))
|
||||
spot::parse_error_list p1;
|
||||
f1 = spot::parse_infix_psl(input, p1);
|
||||
if (spot::format_parse_errors(std::cerr, input, p1))
|
||||
return 2;
|
||||
}
|
||||
else
|
||||
{
|
||||
spot::ltl::parse_error_list p1;
|
||||
f1 = spot::ltl::parse_infix_psl(argv[2], p1);
|
||||
if (spot::ltl::format_parse_errors(std::cerr, argv[2], p1))
|
||||
spot::parse_error_list p1;
|
||||
f1 = spot::parse_infix_psl(argv[2], p1);
|
||||
if (spot::format_parse_errors(std::cerr, argv[2], p1))
|
||||
return 2;
|
||||
}
|
||||
|
||||
|
|
@ -199,23 +199,23 @@ main(int argc, char** argv)
|
|||
exit(2);
|
||||
}
|
||||
|
||||
spot::ltl::parse_error_list p2;
|
||||
f2 = spot::ltl::parse_infix_psl(argv[3], p2);
|
||||
if (spot::ltl::format_parse_errors(std::cerr, argv[3], p2))
|
||||
spot::parse_error_list p2;
|
||||
f2 = spot::parse_infix_psl(argv[3], p2);
|
||||
if (spot::format_parse_errors(std::cerr, argv[3], p2))
|
||||
return 2;
|
||||
}
|
||||
|
||||
{
|
||||
spot::ltl::formula ftmp1;
|
||||
spot::formula ftmp1;
|
||||
|
||||
ftmp1 = f1;
|
||||
f1 = simp_size->negative_normal_form(f1, false);
|
||||
|
||||
int length_f1_before = spot::ltl::length(f1);
|
||||
std::string f1s_before = spot::ltl::str_psl(f1);
|
||||
int length_f1_before = spot::length(f1);
|
||||
std::string f1s_before = spot::str_psl(f1);
|
||||
std::string f1l;
|
||||
|
||||
spot::ltl::formula input_f = f1;
|
||||
spot::formula input_f = f1;
|
||||
f1 = simp_size->simplify(input_f);
|
||||
if (!simp_size->are_equivalent(input_f, f1))
|
||||
{
|
||||
|
|
@ -226,8 +226,8 @@ main(int argc, char** argv)
|
|||
}
|
||||
else
|
||||
{
|
||||
spot::ltl::formula maybe_larger = simp->simplify(input_f);
|
||||
f1l = spot::ltl::str_psl(maybe_larger);
|
||||
spot::formula maybe_larger = simp->simplify(input_f);
|
||||
f1l = spot::str_psl(maybe_larger);
|
||||
if (!simp->are_equivalent(input_f, maybe_larger))
|
||||
{
|
||||
std::cerr << "Incorrect reduction (reduce_size_strictly=0) from `"
|
||||
|
|
@ -236,15 +236,15 @@ main(int argc, char** argv)
|
|||
}
|
||||
}
|
||||
|
||||
int length_f1_after = spot::ltl::length(f1);
|
||||
std::string f1s_after = spot::ltl::str_psl(f1);
|
||||
int length_f1_after = spot::length(f1);
|
||||
std::string f1s_after = spot::str_psl(f1);
|
||||
|
||||
std::string f2s = "";
|
||||
if (f2)
|
||||
{
|
||||
ftmp1 = f2;
|
||||
f2 = simp_size->negative_normal_form(f2, false);
|
||||
f2s = spot::ltl::str_psl(f2);
|
||||
f2s = spot::str_psl(f2);
|
||||
}
|
||||
|
||||
sum_before += length_f1_before;
|
||||
|
|
@ -308,6 +308,6 @@ main(int argc, char** argv)
|
|||
}
|
||||
}
|
||||
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return exit_code;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,25 +45,25 @@ main(int argc, char** argv)
|
|||
int exit_return = 0;
|
||||
|
||||
{
|
||||
spot::ltl::parse_error_list p1;
|
||||
auto ftmp1 = spot::ltl::parse_infix_psl(argv[2], p1);
|
||||
spot::parse_error_list p1;
|
||||
auto ftmp1 = spot::parse_infix_psl(argv[2], p1);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, argv[2], p1))
|
||||
if (spot::format_parse_errors(std::cerr, argv[2], p1))
|
||||
return 2;
|
||||
|
||||
spot::ltl::parse_error_list p2;
|
||||
auto ftmp2 = spot::ltl::parse_infix_psl(argv[3], p2);
|
||||
spot::parse_error_list p2;
|
||||
auto ftmp2 = spot::parse_infix_psl(argv[3], p2);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, argv[3], p2))
|
||||
if (spot::format_parse_errors(std::cerr, argv[3], p2))
|
||||
return 2;
|
||||
|
||||
spot::ltl::formula f1 = spot::ltl::negative_normal_form(ftmp1);
|
||||
spot::ltl::formula f2 = spot::ltl::negative_normal_form(ftmp2);
|
||||
spot::formula f1 = spot::negative_normal_form(ftmp1);
|
||||
spot::formula f2 = spot::negative_normal_form(ftmp2);
|
||||
|
||||
std::string f1s = spot::ltl::str_psl(f1);
|
||||
std::string f2s = spot::ltl::str_psl(f2);
|
||||
std::string f1s = spot::str_psl(f1);
|
||||
std::string f2s = spot::str_psl(f2);
|
||||
|
||||
spot::ltl::ltl_simplifier* c = new spot::ltl::ltl_simplifier;
|
||||
spot::ltl_simplifier* c = new spot::ltl_simplifier;
|
||||
|
||||
switch (opt)
|
||||
{
|
||||
|
|
@ -102,6 +102,6 @@ main(int argc, char** argv)
|
|||
|
||||
delete c;
|
||||
}
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return exit_return;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,8 +28,8 @@ int
|
|||
main()
|
||||
{
|
||||
{
|
||||
spot::ltl::default_environment& e =
|
||||
spot::ltl::default_environment::instance();
|
||||
spot::default_environment& e =
|
||||
spot::default_environment::instance();
|
||||
auto a = spot::make_taa_tgba_string(spot::make_bdd_dict());
|
||||
|
||||
typedef spot::taa_tgba::transition trans;
|
||||
|
|
@ -48,6 +48,6 @@ main()
|
|||
spot::print_dot(std::cout, a);
|
||||
}
|
||||
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -40,21 +40,21 @@ main(int argc, char **argv)
|
|||
syntax(argv[0]);
|
||||
|
||||
{
|
||||
spot::ltl::parse_error_list p1;
|
||||
auto f1 = spot::ltl::parse_infix_psl(argv[1], p1);
|
||||
spot::parse_error_list p1;
|
||||
auto f1 = spot::parse_infix_psl(argv[1], p1);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, argv[1], p1))
|
||||
if (spot::format_parse_errors(std::cerr, argv[1], p1))
|
||||
return 2;
|
||||
|
||||
// The string generated from an abstract tree should be parsable
|
||||
// again.
|
||||
|
||||
std::string f1s = spot::ltl::str_psl(f1);
|
||||
std::string f1s = spot::str_psl(f1);
|
||||
std::cout << f1s << '\n';
|
||||
|
||||
auto f2 = spot::ltl::parse_infix_psl(f1s, p1);
|
||||
auto f2 = spot::parse_infix_psl(f1s, p1);
|
||||
|
||||
if (spot::ltl::format_parse_errors(std::cerr, f1s, p1))
|
||||
if (spot::format_parse_errors(std::cerr, f1s, p1))
|
||||
return 2;
|
||||
|
||||
// This second abstract tree should be equal to the first.
|
||||
|
|
@ -64,13 +64,13 @@ main(int argc, char **argv)
|
|||
|
||||
// It should also map to the same string.
|
||||
|
||||
std::string f2s = spot::ltl::str_psl(f2);
|
||||
std::string f2s = spot::str_psl(f2);
|
||||
std::cout << f2s << '\n';
|
||||
|
||||
if (f2s != f1s)
|
||||
return 1;
|
||||
}
|
||||
|
||||
assert(spot::ltl::fnode::instances_check());
|
||||
assert(spot::fnode::instances_check());
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@
|
|||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
|
||||
# Check for spot::ltl::tostring.
|
||||
# Check for spot::tostring.
|
||||
|
||||
. ./defs || exit 1
|
||||
|
||||
|
|
|
|||
|
|
@ -25,8 +25,6 @@
|
|||
#include "twa/bdddict.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
atomic_prop_set create_atomic_prop_set(unsigned n)
|
||||
{
|
||||
|
|
@ -57,7 +55,7 @@ namespace spot
|
|||
bdd
|
||||
atomic_prop_collect_as_bdd(formula f, const twa_ptr& a)
|
||||
{
|
||||
spot::ltl::atomic_prop_set aps;
|
||||
spot::atomic_prop_set aps;
|
||||
atomic_prop_collect(f, &aps);
|
||||
bdd res = bddtrue;
|
||||
for (auto f: aps)
|
||||
|
|
@ -65,4 +63,3 @@ namespace spot
|
|||
return res;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,8 +28,6 @@
|
|||
#include "twa/fwd.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
/// \addtogroup ltl_misc
|
||||
/// @{
|
||||
|
|
@ -63,4 +61,3 @@ namespace spot
|
|||
|
||||
/// @}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,9 +27,6 @@
|
|||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
|
||||
language_containment_checker::language_containment_checker
|
||||
(const bdd_dict_ptr& dict, bool exprop, bool symb_merge,
|
||||
bool branching_postponement, bool fair_loop_approx)
|
||||
|
|
@ -137,4 +134,3 @@ namespace spot
|
|||
return simpl.simplify(f);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,8 +28,6 @@
|
|||
#include <map>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
/// Check containment between LTL formulae.
|
||||
class SPOT_API language_containment_checker
|
||||
|
|
@ -79,4 +77,3 @@ namespace spot
|
|||
trans_map translated_;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,9 +24,6 @@
|
|||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
|
||||
declarative_environment::declarative_environment()
|
||||
{
|
||||
}
|
||||
|
|
@ -62,4 +59,3 @@ namespace spot
|
|||
return props_;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,9 +29,6 @@
|
|||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
|
||||
/// \ingroup ltl_environment
|
||||
/// \brief A declarative environment.
|
||||
///
|
||||
|
|
@ -61,4 +58,3 @@ namespace spot
|
|||
prop_map props_;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,9 +24,6 @@
|
|||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
|
||||
default_environment::~default_environment()
|
||||
{
|
||||
}
|
||||
|
|
@ -54,6 +51,4 @@ namespace spot
|
|||
static default_environment* singleton = new default_environment();
|
||||
return *singleton;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,9 +27,6 @@
|
|||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
|
||||
/// \ingroup ltl_environment
|
||||
/// \brief A laxist environment.
|
||||
///
|
||||
|
|
@ -44,10 +41,9 @@ namespace spot
|
|||
virtual formula require(const std::string& prop_str);
|
||||
virtual const std::string& name() const;
|
||||
|
||||
/// Get the sole instance of spot::ltl::default_environment.
|
||||
/// Get the sole instance of spot::default_environment.
|
||||
static default_environment& instance();
|
||||
protected:
|
||||
default_environment();
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,8 +27,6 @@
|
|||
#include <sstream>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
namespace
|
||||
{
|
||||
|
|
@ -134,4 +132,3 @@ namespace spot
|
|||
return os;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -25,8 +25,6 @@
|
|||
#include "formula.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
/// \ingroup ltl_io
|
||||
/// \brief Write a formula tree using dot's syntax.
|
||||
|
|
@ -38,4 +36,3 @@ namespace spot
|
|||
SPOT_API
|
||||
std::ostream& print_dot_psl(std::ostream& os, formula f);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,8 +26,6 @@
|
|||
#include <string>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
/// \ingroup ltl_essential
|
||||
/// \brief An environment that describes atomic propositions.
|
||||
|
|
@ -37,14 +35,14 @@ namespace spot
|
|||
/// \brief Obtain the formula associated to \a prop_str
|
||||
///
|
||||
/// Usually \a prop_str, is the name of an atomic proposition,
|
||||
/// and spot::ltl::require simply returns the associated
|
||||
/// spot::ltl::formula.
|
||||
/// and spot::require simply returns the associated
|
||||
/// spot::formula.
|
||||
///
|
||||
/// Note this is not a \c const method. Some environments will
|
||||
/// "create" the atomic proposition when requested.
|
||||
///
|
||||
/// \return 0 iff \a prop_str is not part of the environment,
|
||||
/// or the associated spot::ltl::formula otherwise.
|
||||
/// or the associated spot::formula otherwise.
|
||||
virtual formula require(const std::string& prop_str) = 0;
|
||||
|
||||
/// Get the name of the environment.
|
||||
|
|
@ -55,6 +53,4 @@ namespace spot
|
|||
{
|
||||
}
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,10 +27,10 @@ namespace spot
|
|||
{
|
||||
namespace
|
||||
{
|
||||
static const std::vector<ltl::formula>
|
||||
static const std::vector<formula>
|
||||
split_aps(const char* arg)
|
||||
{
|
||||
std::vector<ltl::formula> group;
|
||||
std::vector<formula> group;
|
||||
auto start = arg;
|
||||
while (*start)
|
||||
{
|
||||
|
|
@ -61,7 +61,7 @@ namespace spot
|
|||
throw std::invalid_argument(s);
|
||||
}
|
||||
std::string ap(start, end - start);
|
||||
group.emplace_back(ltl::formula::ap(ap));
|
||||
group.emplace_back(formula::ap(ap));
|
||||
do
|
||||
++end;
|
||||
while (*end == ' ' || *end == '\t');
|
||||
|
|
@ -86,7 +86,7 @@ namespace spot
|
|||
while (rend > start && (rend[-1] == ' ' || rend[-1] == '\t'))
|
||||
--rend;
|
||||
std::string ap(start, rend - start);
|
||||
group.emplace_back(ltl::formula::ap(ap));
|
||||
group.emplace_back(formula::ap(ap));
|
||||
if (*end == ',')
|
||||
start = end + 1;
|
||||
else
|
||||
|
|
@ -102,27 +102,27 @@ namespace spot
|
|||
add_group(split_aps(ap_csv));
|
||||
}
|
||||
|
||||
void exclusive_ap::add_group(std::vector<ltl::formula> ap)
|
||||
void exclusive_ap::add_group(std::vector<formula> ap)
|
||||
{
|
||||
groups.push_back(ap);
|
||||
}
|
||||
|
||||
namespace
|
||||
{
|
||||
ltl::formula
|
||||
nand(ltl::formula lhs, ltl::formula rhs)
|
||||
formula
|
||||
nand(formula lhs, formula rhs)
|
||||
{
|
||||
return ltl::formula::Not(ltl::formula::And({lhs, rhs}));
|
||||
return formula::Not(formula::And({lhs, rhs}));
|
||||
}
|
||||
}
|
||||
|
||||
ltl::formula
|
||||
exclusive_ap::constrain(ltl::formula f) const
|
||||
formula
|
||||
exclusive_ap::constrain(formula f) const
|
||||
{
|
||||
auto* s = atomic_prop_collect(f);
|
||||
|
||||
std::vector<ltl::formula> group;
|
||||
std::vector<ltl::formula> v;
|
||||
std::vector<formula> group;
|
||||
std::vector<formula> v;
|
||||
|
||||
for (auto& g: groups)
|
||||
{
|
||||
|
|
@ -139,7 +139,7 @@ namespace spot
|
|||
};
|
||||
|
||||
delete s;
|
||||
return ltl::formula::And({f, ltl::formula::G(ltl::formula::And(v))});
|
||||
return formula::And({f, formula::G(formula::And(v))});
|
||||
}
|
||||
|
||||
twa_graph_ptr exclusive_ap::constrain(const_twa_graph_ptr aut,
|
||||
|
|
|
|||
|
|
@ -27,10 +27,10 @@ namespace spot
|
|||
{
|
||||
class SPOT_API exclusive_ap final
|
||||
{
|
||||
std::vector<std::vector<ltl::formula>> groups;
|
||||
std::vector<std::vector<formula>> groups;
|
||||
public:
|
||||
#ifndef SWIG
|
||||
void add_group(std::vector<ltl::formula> ap);
|
||||
void add_group(std::vector<formula> ap);
|
||||
#endif
|
||||
void add_group(const char* ap_csv);
|
||||
|
||||
|
|
@ -39,7 +39,7 @@ namespace spot
|
|||
return groups.empty();
|
||||
}
|
||||
|
||||
ltl::formula constrain(ltl::formula f) const;
|
||||
formula constrain(formula f) const;
|
||||
twa_graph_ptr constrain(const_twa_graph_ptr aut,
|
||||
bool simplify_guards = false) const;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ namespace spot
|
|||
{
|
||||
namespace
|
||||
{
|
||||
typedef std::vector<const ltl::fnode*> vec;
|
||||
typedef std::vector<const fnode*> vec;
|
||||
|
||||
// Compare two formulas, by looking at their operators and
|
||||
// children. This does not use id for the top-level operator,
|
||||
|
|
@ -45,14 +45,14 @@ namespace spot
|
|||
// formula.
|
||||
struct formula_cmp
|
||||
{
|
||||
bool operator()(const ltl::fnode* l, const ltl::fnode* r) const
|
||||
bool operator()(const fnode* l, const fnode* r) const
|
||||
{
|
||||
ltl::op opl = l->kind();
|
||||
ltl::op opr = r->kind();
|
||||
op opl = l->kind();
|
||||
op opr = r->kind();
|
||||
if (opl != opr)
|
||||
return opl < opr;
|
||||
|
||||
if (SPOT_UNLIKELY(opl == ltl::op::Star || opl == ltl::op::FStar))
|
||||
if (SPOT_UNLIKELY(opl == op::Star || opl == op::FStar))
|
||||
{
|
||||
{
|
||||
auto minl = l->min();
|
||||
|
|
@ -87,15 +87,15 @@ namespace spot
|
|||
|
||||
struct maps_t final
|
||||
{
|
||||
std::map<std::string, const ltl::fnode*> name2ap;
|
||||
std::map<std::string, const fnode*> name2ap;
|
||||
std::map<size_t, std::string> ap2name;
|
||||
|
||||
std::set<const ltl::fnode*, formula_cmp> uniq;
|
||||
std::set<const fnode*, formula_cmp> uniq;
|
||||
};
|
||||
static maps_t m;
|
||||
|
||||
static void
|
||||
gather_bool(vec& v, ltl::op o)
|
||||
gather_bool(vec& v, op o)
|
||||
{
|
||||
// Gather all boolean terms.
|
||||
vec b;
|
||||
|
|
@ -119,12 +119,10 @@ namespace spot
|
|||
// - OrRat(Exps1...,Bool1,Exps2...,Bool2,Exps3...) =
|
||||
// AndRat(Or(Bool1,Bool2),Exps1...,Exps2...,Exps3...)
|
||||
if (!b.empty())
|
||||
v.insert(v.begin(), ltl::fnode::multop(o, std::move(b)));
|
||||
v.insert(v.begin(), fnode::multop(o, std::move(b)));
|
||||
}
|
||||
}
|
||||
|
||||
namespace ltl
|
||||
{
|
||||
const fnode* fnode::unique(const fnode* f)
|
||||
{
|
||||
auto ires = m.uniq.emplace(f);
|
||||
|
|
@ -993,7 +991,6 @@ namespace spot
|
|||
return unique(new(mem) fnode(o, {first, second}));
|
||||
}
|
||||
|
||||
|
||||
const fnode*
|
||||
fnode::ap(const std::string& name)
|
||||
{
|
||||
|
|
@ -1747,4 +1744,3 @@ namespace spot
|
|||
return out;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
// You should have received a copy of the GNU General Public License
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
/// \file tlformula.hh
|
||||
/// \file tl/formula.hh
|
||||
/// \brief LTL/PSL formula interface
|
||||
#pragma once
|
||||
|
||||
|
|
@ -36,8 +36,6 @@
|
|||
#include <initializer_list>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
enum class op: uint8_t
|
||||
{
|
||||
|
|
@ -1261,15 +1259,14 @@ namespace spot
|
|||
SPOT_API
|
||||
std::list<std::string> list_formula_props(const formula& f);
|
||||
}
|
||||
}
|
||||
|
||||
#ifndef SWIG
|
||||
namespace std
|
||||
{
|
||||
template <>
|
||||
struct hash<spot::ltl::formula>
|
||||
struct hash<spot::formula>
|
||||
{
|
||||
size_t operator()(const spot::ltl::formula& x) const noexcept
|
||||
size_t operator()(const spot::formula& x) const noexcept
|
||||
{
|
||||
return x.id();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,8 +24,6 @@
|
|||
#include "formula.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
int
|
||||
length(formula f)
|
||||
|
|
@ -77,4 +75,3 @@ namespace spot
|
|||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -25,8 +25,6 @@
|
|||
#include "formula.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
/// \ingroup ltl_misc
|
||||
/// \brief Compute the length of a formula.
|
||||
|
|
@ -45,9 +43,8 @@ namespace spot
|
|||
/// \ingroup ltl_misc
|
||||
/// \brief Compute the length of a formula, squashing Boolean formulae
|
||||
///
|
||||
/// This is similar to spot::ltl::length(), except all Boolean
|
||||
/// This is similar to spot::length(), except all Boolean
|
||||
/// formulae are assumed to have length one.
|
||||
SPOT_API
|
||||
int length_boolone(formula f);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,8 +24,6 @@
|
|||
#include <vector>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
formula
|
||||
mark_tools::mark_concat_ops(formula f)
|
||||
|
|
@ -34,7 +32,7 @@ namespace spot
|
|||
if (i != markops_.end())
|
||||
return i->second;
|
||||
|
||||
ltl::formula res;
|
||||
formula res;
|
||||
switch (f.kind())
|
||||
{
|
||||
case op::ff:
|
||||
|
|
@ -63,10 +61,10 @@ namespace spot
|
|||
res = f;
|
||||
break;
|
||||
case op::NegClosure:
|
||||
res = ltl::formula::NegClosureMarked(f[0]);
|
||||
res = formula::NegClosureMarked(f[0]);
|
||||
break;
|
||||
case op::EConcat:
|
||||
res = ltl::formula::EConcatMarked(f[0], f[1]);
|
||||
res = formula::EConcatMarked(f[0], f[1]);
|
||||
break;
|
||||
case op::Or:
|
||||
case op::And:
|
||||
|
|
@ -100,7 +98,7 @@ namespace spot
|
|||
return this->simplify_mark(f);
|
||||
};
|
||||
|
||||
ltl::formula res;
|
||||
formula res;
|
||||
switch (f.kind())
|
||||
{
|
||||
case op::ff:
|
||||
|
|
@ -170,7 +168,7 @@ namespace spot
|
|||
for (auto n: nlist)
|
||||
if (nmset.find(n[0]) == nmset.end())
|
||||
v.push_back(n);
|
||||
res = ltl::formula::And(v);
|
||||
res = formula::And(v);
|
||||
}
|
||||
break;
|
||||
case op::Xor:
|
||||
|
|
@ -189,6 +187,4 @@ namespace spot
|
|||
simpmark_[f] = res;
|
||||
return res;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,8 +23,6 @@
|
|||
#include "misc/hash.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
class mark_tools final
|
||||
{
|
||||
|
|
@ -42,6 +40,4 @@ namespace spot
|
|||
f2f_map simpmark_;
|
||||
f2f_map markops_;
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,8 +31,6 @@
|
|||
#define Not_(x) formula::Not(x)
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
namespace
|
||||
{
|
||||
|
|
@ -368,4 +366,3 @@ namespace spot
|
|||
return res;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,8 +23,6 @@
|
|||
#include <vector>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
enum mut_opts
|
||||
{
|
||||
|
|
@ -45,4 +43,3 @@ namespace spot
|
|||
unsigned mutation_count = 1,
|
||||
bool sort = true);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,8 +24,6 @@
|
|||
#include "simplify.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
formula
|
||||
negative_normal_form(formula f, bool negated)
|
||||
|
|
@ -36,6 +34,4 @@ namespace spot
|
|||
ltl_simplifier s;
|
||||
return s.negative_normal_form(f, negated);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -25,8 +25,6 @@
|
|||
#include "formula.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
/// \ingroup ltl_rewriting
|
||||
/// \brief Build the negative normal form of \a f.
|
||||
|
|
@ -39,11 +37,10 @@ namespace spot
|
|||
/// \c !f
|
||||
///
|
||||
/// Note that this will not remove abbreviated operators. If you
|
||||
/// want to remove abbreviations, call spot::ltl::unabbreviate
|
||||
/// want to remove abbreviations, call spot::unabbreviate
|
||||
/// first. (Calling this function after
|
||||
/// spot::ltl::negative_normal_form would likely produce a formula
|
||||
/// spot::negative_normal_form would likely produce a formula
|
||||
/// which is not in negative normal form.)
|
||||
SPOT_API formula
|
||||
negative_normal_form(formula f, bool negated = false);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,8 +30,6 @@
|
|||
#include "misc/escape.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
namespace
|
||||
{
|
||||
|
|
@ -1139,6 +1137,4 @@ namespace spot
|
|||
print_lbt_ltl(os, f);
|
||||
return os.str();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,8 +26,6 @@
|
|||
#include <iosfwd>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
/// \addtogroup ltl_io
|
||||
/// @{
|
||||
|
|
@ -221,4 +219,3 @@ namespace spot
|
|||
str_lbt_ltl(formula f);
|
||||
/// @}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -31,8 +31,6 @@
|
|||
#include <sstream>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
namespace
|
||||
{
|
||||
|
|
@ -583,4 +581,3 @@ namespace spot
|
|||
rs_->rb.dump_priorities(os);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,9 +38,6 @@
|
|||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
|
||||
/// \ingroup ltl_io
|
||||
/// \brief Base class for random formula generators
|
||||
class SPOT_API random_formula
|
||||
|
|
@ -69,7 +66,7 @@ namespace spot
|
|||
/// It is possible to obtain formulae that are smaller than \a
|
||||
/// n, because some simple simplifications are performed by the
|
||||
/// AST. (For instance the formula <code>a | a</code> is
|
||||
/// automatically reduced to <code>a</code> by spot::ltl::multop.)
|
||||
/// automatically reduced to <code>a</code> by spot::multop.)
|
||||
formula generate(int n) const;
|
||||
|
||||
/// \brief Print the priorities of each operator, constants,
|
||||
|
|
@ -350,4 +347,3 @@ namespace spot
|
|||
random_sere* rs_ = nullptr;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,9 +27,6 @@
|
|||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
// Basic relabeler
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
|
@ -484,4 +481,3 @@ namespace spot
|
|||
return rel.visit(f);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,8 +24,6 @@
|
|||
#include <map>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
enum relabeling_style { Abc, Pnn };
|
||||
|
||||
|
|
@ -51,4 +49,3 @@ namespace spot
|
|||
formula relabel_bse(formula f, relabeling_style style,
|
||||
relabeling_map* m = nullptr);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -22,8 +22,6 @@
|
|||
#include "remove_x.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
namespace
|
||||
{
|
||||
|
|
@ -99,4 +97,3 @@ namespace spot
|
|||
return remove_x_rec(f, aps);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -22,8 +22,6 @@
|
|||
#include "formula.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
/// \brief Rewrite a stutter-insensitive formula \a f without
|
||||
/// using the X operator.
|
||||
|
|
@ -46,4 +44,3 @@ namespace spot
|
|||
SPOT_API
|
||||
formula remove_x(formula f);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,8 +23,6 @@
|
|||
#include "simpfg.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
formula simplify_f_g(formula p)
|
||||
{
|
||||
|
|
@ -42,6 +40,4 @@ namespace spot
|
|||
return formula::F(p[0]);
|
||||
return p.map(simplify_f_g);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -25,8 +25,6 @@
|
|||
#include "formula.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
/// \ingroup ltl_rewriting
|
||||
/// \brief Replace <code>true U f</code> and <code>false R g</code> by
|
||||
|
|
@ -41,4 +39,3 @@ namespace spot
|
|||
///
|
||||
SPOT_API formula simplify_f_g(formula f);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -35,8 +35,6 @@
|
|||
#include <memory>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
typedef std::vector<formula> vec;
|
||||
|
||||
|
|
@ -278,13 +276,13 @@ namespace spot
|
|||
formula
|
||||
star_normal_form(formula f)
|
||||
{
|
||||
return ltl::star_normal_form(f, &snf_cache_);
|
||||
return spot::star_normal_form(f, &snf_cache_);
|
||||
}
|
||||
|
||||
formula
|
||||
star_normal_form_bounded(formula f)
|
||||
{
|
||||
return ltl::star_normal_form_bounded(f, &snfb_cache_);
|
||||
return spot::star_normal_form_bounded(f, &snfb_cache_);
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -3446,4 +3444,3 @@ namespace spot
|
|||
cache_->lcc.clear();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -25,8 +25,6 @@
|
|||
#include <iosfwd>
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
class ltl_simplifier_options
|
||||
{
|
||||
|
|
@ -111,7 +109,7 @@ namespace spot
|
|||
/// Build the negative normal form of formula \a f.
|
||||
/// All negations of the formula are pushed in front of the
|
||||
/// atomic propositions. Operators <=>, =>, xor are all removed
|
||||
/// (calling spot::ltl::unabbreviate_ltl is not needed).
|
||||
/// (calling spot::unabbreviate_ltl is not needed).
|
||||
///
|
||||
/// \param f The formula to normalize.
|
||||
/// \param negated If \c true, return the negative normal form of
|
||||
|
|
@ -181,7 +179,7 @@ namespace spot
|
|||
/// Return the bdd_dict used.
|
||||
bdd_dict_ptr get_dict() const;
|
||||
|
||||
/// Cached version of spot::ltl::star_normal_form().
|
||||
/// Cached version of spot::star_normal_form().
|
||||
formula star_normal_form(formula f);
|
||||
|
||||
/// \brief Rewrite a Boolean formula \a f into as an irredundant
|
||||
|
|
@ -201,4 +199,3 @@ namespace spot
|
|||
void operator=(const ltl_simplifier&) SPOT_DELETED;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -20,8 +20,6 @@
|
|||
#include "snf.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
namespace
|
||||
{
|
||||
|
|
@ -144,6 +142,4 @@ namespace spot
|
|||
snf_visitor<true> v(cache);
|
||||
return v.visit(sere);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,9 +24,6 @@
|
|||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
|
||||
typedef std::unordered_map<formula, formula> snf_cache;
|
||||
|
||||
/// Helper to rewrite a sere in Star Normal Form.
|
||||
|
|
@ -55,4 +52,3 @@ namespace spot
|
|||
SPOT_API formula
|
||||
star_normal_form_bounded(formula sere, snf_cache* cache = nullptr);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -21,8 +21,6 @@
|
|||
#include "unabbrev.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
namespace ltl
|
||||
{
|
||||
unabbreviator::unabbreviator(const char* opt)
|
||||
{
|
||||
|
|
@ -250,4 +248,3 @@ namespace spot
|
|||
return un.run(in);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue