include config.h in all *.cc files

This helps working around missing C functions like strcasecmp that do
not exist everywhere (e.g. on Cygwin), and for which lib/ supplies a
replacement.  Unfortunately we do not have such build in our current
continuous integration suite, so we cannot easily detect files where
such config.h inclusion would be useful.  Therefore this patch simply
makes it mandatory to include config.h in *.cc files.  Including this
in public *.hh file is currently forbidden.

* spot/gen/automata.cc, spot/gen/formulas.cc,
spot/kripke/fairkripke.cc, spot/kripke/kripke.cc,
spot/ltsmin/ltsmin.cc, spot/misc/game.cc, spot/parseaut/fmterror.cc,
spot/parsetl/fmterror.cc, spot/parsetl/parsetl.yy,
spot/priv/bddalloc.cc, spot/priv/freelist.cc, spot/priv/satcommon.cc,
spot/priv/trim.cc, spot/priv/weight.cc, spot/ta/ta.cc,
spot/ta/taexplicit.cc, spot/ta/taproduct.cc, spot/ta/tgtaexplicit.cc,
spot/ta/tgtaproduct.cc, spot/taalgos/dot.cc,
spot/taalgos/emptinessta.cc, spot/taalgos/minimize.cc,
spot/taalgos/reachiter.cc, spot/taalgos/statessetbuilder.cc,
spot/taalgos/stats.cc, spot/taalgos/tgba2ta.cc, spot/tl/apcollect.cc,
spot/tl/contain.cc, spot/tl/declenv.cc, spot/tl/defaultenv.cc,
spot/tl/dot.cc, spot/tl/exclusive.cc, spot/tl/hierarchy.cc,
spot/tl/length.cc, spot/tl/ltlf.cc, spot/tl/mark.cc,
spot/tl/mutation.cc, spot/tl/nenoform.cc, spot/tl/print.cc,
spot/tl/randomltl.cc, spot/tl/relabel.cc, spot/tl/remove_x.cc,
spot/tl/simplify.cc, spot/tl/snf.cc, spot/tl/unabbrev.cc,
spot/twa/acc.cc, spot/twa/bdddict.cc, spot/twa/bddprint.cc,
spot/twa/formula2bdd.cc, spot/twa/taatgba.cc, spot/twa/twa.cc,
spot/twa/twagraph.cc, spot/twa/twaproduct.cc, spot/twaalgos/aiger.cc,
spot/twaalgos/alternation.cc, spot/twaalgos/are_isomorphic.cc,
spot/twaalgos/bfssteps.cc, spot/twaalgos/canonicalize.cc,
spot/twaalgos/cleanacc.cc, spot/twaalgos/cobuchi.cc,
spot/twaalgos/complement.cc, spot/twaalgos/complete.cc,
spot/twaalgos/compsusp.cc, spot/twaalgos/couvreurnew.cc,
spot/twaalgos/cycles.cc, spot/twaalgos/degen.cc,
spot/twaalgos/determinize.cc, spot/twaalgos/dot.cc,
spot/twaalgos/dtbasat.cc, spot/twaalgos/dtwasat.cc,
spot/twaalgos/dualize.cc, spot/twaalgos/emptiness.cc,
spot/twaalgos/gtec/ce.cc, spot/twaalgos/gtec/gtec.cc,
spot/twaalgos/gtec/sccstack.cc, spot/twaalgos/gtec/status.cc,
spot/twaalgos/gv04.cc, spot/twaalgos/hoa.cc,
spot/twaalgos/iscolored.cc, spot/twaalgos/isdet.cc,
spot/twaalgos/isunamb.cc, spot/twaalgos/isweakscc.cc,
spot/twaalgos/langmap.cc, spot/twaalgos/lbtt.cc,
spot/twaalgos/ltl2taa.cc, spot/twaalgos/ltl2tgba_fm.cc,
spot/twaalgos/magic.cc, spot/twaalgos/mask.cc,
spot/twaalgos/minimize.cc, spot/twaalgos/neverclaim.cc,
spot/twaalgos/parity.cc, spot/twaalgos/postproc.cc,
spot/twaalgos/powerset.cc, spot/twaalgos/product.cc,
spot/twaalgos/rabin2parity.cc, spot/twaalgos/randomgraph.cc,
spot/twaalgos/randomize.cc, spot/twaalgos/reachiter.cc,
spot/twaalgos/relabel.cc, spot/twaalgos/remfin.cc,
spot/twaalgos/remprop.cc, spot/twaalgos/sbacc.cc,
spot/twaalgos/sccfilter.cc, spot/twaalgos/sccinfo.cc,
spot/twaalgos/se05.cc, spot/twaalgos/sepsets.cc,
spot/twaalgos/simulation.cc, spot/twaalgos/split.cc,
spot/twaalgos/stats.cc, spot/twaalgos/strength.cc,
spot/twaalgos/stripacc.cc, spot/twaalgos/stutter.cc,
spot/twaalgos/sum.cc, spot/twaalgos/tau03.cc,
spot/twaalgos/tau03opt.cc, spot/twaalgos/totgba.cc,
spot/twaalgos/toweak.cc, spot/twaalgos/translate.cc,
spot/twaalgos/word.cc, tests/core/acc.cc, tests/core/bitvect.cc,
tests/core/checkpsl.cc, tests/core/checkta.cc, tests/core/consterm.cc,
tests/core/emptchk.cc, tests/core/equalsf.cc, tests/core/graph.cc,
tests/core/ikwiad.cc, tests/core/intvcmp2.cc, tests/core/intvcomp.cc,
tests/core/kind.cc, tests/core/kripkecat.cc, tests/core/length.cc,
tests/core/ltlrel.cc, tests/core/ngraph.cc, tests/core/parity.cc,
tests/core/randtgba.cc, tests/core/readltl.cc, tests/core/reduc.cc,
tests/core/safra.cc, tests/core/sccif.cc, tests/core/syntimpl.cc,
tests/core/taatgba.cc, tests/core/tostring.cc, tests/core/trival.cc,
tests/core/twagraph.cc, tests/ltsmin/modelcheck.cc,
spot/parseaut/scanaut.ll, spot/parsetl/scantl.ll: Include config.h.
* spot/gen/Makefile.am, spot/graph/Makefile.am,
spot/kripke/Makefile.am, spot/ltsmin/Makefile.am,
spot/parseaut/Makefile.am, spot/parsetl/Makefile.am,
spot/priv/Makefile.am, spot/ta/Makefile.am, spot/taalgos/Makefile.am,
spot/tl/Makefile.am, spot/twa/Makefile.am, spot/twaalgos/Makefile.am,
spot/twaalgos/gtec/Makefile.am, tests/Makefile.am: Add the -I lib/
flags.
* tests/sanity/includes.test: Catch missing config.h in *.cc, and
diagnose config.h in *.hh.
* tests/sanity/style.test: Better diagnostics.
This commit is contained in:
Alexandre Duret-Lutz 2018-02-20 21:42:59 +01:00
parent cdec6b28a2
commit ac6b0c9432
165 changed files with 493 additions and 324 deletions

View file

@ -1,5 +1,5 @@
## -*- coding: utf-8 -*-
## Copyright (C) 2008-2017 Laboratoire de Recherche et Développement
## Copyright (C) 2008-2018 Laboratoire de Recherche et Développement
## de l'Epita (LRDE).
## Copyright (C) 2003-2005 Laboratoire d'Informatique de Paris 6
## (LIP6), département Systèmes Répartis Coopératifs (SRC), Université
@ -22,7 +22,8 @@
SUBDIRS = gtec
AM_CPPFLAGS = -I$(top_builddir) -I$(top_srcdir) $(BUDDY_CPPFLAGS)
AM_CPPFLAGS = -I$(top_builddir) -I$(top_srcdir) $(BUDDY_CPPFLAGS) \
-I$(top_builddir)/lib -I$(top_srcdir)/lib
AM_CXXFLAGS = $(WARNING_CXXFLAGS)
twaalgosdir = $(pkgincludedir)/twaalgos

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2017 Laboratoire de Recherche et Développement
// Copyright (C) 2017-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/aiger.hh>
#include <cmath>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2016, 2017 Laboratoire de Recherche et Développement
// Copyright (C) 2016-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <algorithm>
#include <sstream>
#include <spot/twaalgos/alternation.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2014-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2014-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
// Copyright (C) 2004, 2005 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
@ -20,6 +20,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/>.
#include "config.h"
#include <spot/twa/twagraph.hh>
#include <spot/twaalgos/are_isomorphic.hh>
#include <spot/twaalgos/canonicalize.hh>

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2014, 2015 Laboratoire de Recherche et Développement
// de l'Epita (LRDE)
// Copyright (C) 2014, 2015, 2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE)
// Copyright (C) 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
// et Marie Curie.
@ -20,6 +20,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/>.
#include "config.h"
#include <deque>
#include <utility>
#include <spot/twa/twa.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2014-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2014-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/canonicalize.hh>
#include <spot/twa/twagraph.hh>
#include <set>

View file

@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/cleanacc.hh>
namespace spot

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2017, 2018 Laboratoire de Recherche et Développement
// Copyright (C) 2017-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/cobuchi.hh>
#include <spot/misc/bddlt.hh>
@ -35,11 +36,11 @@
#include <stack>
#include <unordered_map>
#define DEBUG 0
#if DEBUG
#define debug std::cerr
#define TRACE 0
#if TRACE
#define trace std::cerr
#else
#define debug while (0) std::cout
#define trace while (0) std::cout
#endif
namespace spot
@ -461,7 +462,7 @@ namespace spot
}
}
}
debug << "All_states:\n" << *bv_aut_trans_ << '\n';
trace << "All_states:\n" << *bv_aut_trans_ << '\n';
twa_graph_ptr res = make_twa_graph(aut_->get_dict());
res->copy_ap_of(aut_);
@ -548,14 +549,14 @@ namespace spot
bv_trans_mark->at(l) |= bv_aut_trans_->at(s * nc + l);
toclean_.push_back(bv_trans_mark);
debug << "src:" << top.second;
trace << "src:" << top.second;
if (named_states)
debug << ' ' << (*state_name)[top.second];
debug << '\n';
trace << ' ' << (*state_name)[top.second];
trace << '\n';
for (unsigned l = 0; l < nc; ++l)
{
debug << "l: "
trace << "l: "
<< bdd_format_formula(aut_->get_dict(), num2bdd_[l])
<< '\n';
@ -582,12 +583,12 @@ namespace spot
(top.first.first + 1) % (nb_copy_ + 1)
: top.first.first;
debug << "dest\n" << *bv_res << "i: " << i << '\n';
trace << "dest\n" << *bv_res << "i: " << i << '\n';
res->new_edge(top.second,
new_state(std::make_pair(i, bv_res)),
num2bdd_[l]);
}
debug << '\n';
trace << '\n';
}
// Set rejecting states.
@ -617,7 +618,7 @@ namespace spot
twa_graph_ptr
nsa_to_dca(const_twa_graph_ptr aut, bool named_states)
{
debug << "NSA_to_dca\n";
trace << "NSA_to_dca\n";
std::vector<acc_cond::rs_pair> pairs;
if (!aut->acc().is_streett_like(pairs) && !aut->acc().is_parity())
throw std::runtime_error("nsa_to_dca() only works with Streett-like or "
@ -632,10 +633,10 @@ namespace spot
vect_nca_info nca_info;
nsa_to_nca(aut, named_states, &nca_info);
#if DEBUG
debug << "PRINTING INFO\n";
#if TRACE
trace << "PRINTING INFO\n";
for (unsigned i = 0; i < nca_info.size(); ++i)
debug << '<' << nca_info[i]->clause_num << ',' << nca_info[i]->state_num
trace << '<' << nca_info[i]->clause_num << ',' << nca_info[i]->state_num
<< ',' << *nca_info[i]->all_dst << ">\n";
#endif
@ -647,7 +648,7 @@ namespace spot
twa_graph_ptr
dnf_to_dca(const_twa_graph_ptr aut, bool named_states)
{
debug << "DNF_to_dca\n";
trace << "DNF_to_dca\n";
const acc_cond::acc_code& code = aut->get_acceptance();
if (!code.is_dnf())
throw std::runtime_error("dnf_to_dca() only works with DNF (Rabin-like "
@ -662,10 +663,10 @@ namespace spot
vect_nca_info nca_info;
dnf_to_nca(aut, false, &nca_info);
#if DEBUG
debug << "PRINTING INFO\n";
#if TRACE
trace << "PRINTING INFO\n";
for (unsigned i = 0; i < nca_info.size(); ++i)
debug << '<' << nca_info[i]->clause_num << ',' << nca_info[i]->state_num
trace << '<' << nca_info[i]->clause_num << ',' << nca_info[i]->state_num
<< ',' << *nca_info[i]->all_dst << ">\n";
#endif

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2013-2015, 2017 Laboratoire de Recherche et
// Copyright (C) 2013-2015, 2017-2018 Laboratoire de Recherche et
// Développement de l'Epita.
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/complement.hh>
#include <spot/twaalgos/dualize.hh>
#include <spot/twaalgos/isdet.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2013-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2013-2018 Laboratoire de Recherche et Développement
// de l'Epita.
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/complete.hh>
namespace spot

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2012, 2013, 2014, 2015 Laboratoire de Recherche et
// Copyright (C) 2012-2015, 2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/compsusp.hh>
#include <spot/twaalgos/sccfilter.hh>
#include <spot/twaalgos/sccinfo.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2016-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2016-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/couvreurnew.hh>
#include <spot/twa/twa.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2012, 2014-2017 Laboratoire de Recherche et
// Copyright (C) 2012, 2014-2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <iostream>
#include <spot/twaalgos/cycles.hh>

View file

@ -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/>.
#include "config.h"
#include <spot/twaalgos/degen.hh>
#include <spot/twa/twagraph.hh>
#include <spot/misc/hash.hh>

View file

@ -17,6 +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/>.
#include "config.h"
#include <algorithm>
#include <deque>
#include <stack>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2011, 2012, 2014-2017 Laboratoire de Recherche
// Copyright (C) 2011, 2012, 2014-2018 Laboratoire de Recherche
// et Développement de l'Epita (LRDE).
// Copyright (C) 2003, 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
@ -20,6 +20,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/>.
#include "config.h"
#include <ostream>
#include <sstream>
#include <stdexcept>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2013, 2014, 2015, 2016, 2017 Laboratoire de Recherche
// Copyright (C) 2013-2018 Laboratoire de Recherche
// et Développement de l'Epita.
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <fstream>
#include <sstream>
#include <map>
@ -33,14 +34,14 @@
// file used to communicate with the sat solver will be left in
// the current directory.
//
// Additionally, if the following DEBUG macro is set to 1, the CNF
// Additionally, if the following TRACE macro is set to 1, the CNF
// file will be output with a comment before each clause, and an
// additional output file (dtba-sat.dbg) will be created with a list
// of all positive variables in the result and their meaning.
#define DEBUG 0
#define TRACE 0
#if DEBUG
#if TRACE
#define dout out << "c "
#define cnf_comment(...) solver.comment(__VA_ARGS__)
#define trace std::cerr
@ -105,7 +106,7 @@ namespace spot
int
transid(unsigned src, bdd& cond, unsigned dst)
{
#if DEBUG
#if TRACE
try
{
return helper.get_t(src, alpha_map.at(cond), dst);
@ -130,7 +131,7 @@ namespace spot
int
transacc(unsigned src, bdd& cond, unsigned dst)
{
#if DEBUG
#if TRACE
try
{
return helper.get_ta(src, alpha_map.at(cond), dst);
@ -150,7 +151,7 @@ namespace spot
pathid_ref(unsigned src_cand, unsigned src_ref, unsigned dst_cand,
unsigned dst_ref)
{
#if DEBUG
#if TRACE
try
{
return helper.get_prc(
@ -169,7 +170,7 @@ namespace spot
#endif
}
#if DEBUG
#if TRACE
int
pathid_ref(unsigned path, unsigned src_cand, unsigned dst_cand)
{
@ -187,7 +188,7 @@ namespace spot
pathid_cand(unsigned src_cand, unsigned src_ref, unsigned dst_cand,
unsigned dst_ref)
{
#if DEBUG
#if TRACE
try
{
return helper.get_prc(
@ -330,7 +331,7 @@ namespace spot
// Empty automaton is impossible.
assert(d.cand_size > 0);
#if DEBUG
#if TRACE
debug_dict = ref->get_dict();
solver.comment("d.ref_size", d.ref_size, '\n');
solver.comment("d.cand_size", d.cand_size, '\n');
@ -353,7 +354,7 @@ namespace spot
for (unsigned q1 = 0; q1 < d.cand_size; ++q1)
for (unsigned l = 0; l < alpha_size; ++l)
{
#if DEBUG
#if TRACE
solver.comment("");
for (unsigned q2 = 0; q2 < d.cand_size; q2++)
{
@ -457,7 +458,7 @@ namespace spot
{
bdd s = bdd_satoneset(all, ap, bddfalse);
all -= s;
#if DEBUG
#if TRACE
std::string f_t = d.fmt_t(q2, s, q1);
cnf_comment(f_p, "R ∧", f_t, "δ → ¬", f_t,
"F\n");
@ -544,7 +545,7 @@ namespace spot
{
bdd s = bdd_satoneset(all, ap, bddfalse);
all -= s;
#if DEBUG
#if TRACE
std::string f_t = d.fmt_t(q2, s, q1);
cnf_comment(f_p, "C ∧", f_t, "δ →", f_t,
"F\n");
@ -566,7 +567,7 @@ namespace spot
{
bdd s = bdd_satoneset(all, ap, bddfalse);
all -= s;
#if DEBUG
#if TRACE
std::string f_t = d.fmt_t(q2, s, q3);
cnf_comment(f_p, "C ∧", f_t, "δ ∧ ¬", f_t,
"F →", d.fmt_p(q1, q1p, q3, dp),
@ -602,7 +603,7 @@ namespace spot
a->prop_universal(true);
a->new_states(satdict.cand_size);
#if DEBUG
#if TRACE
std::fstream out("dtba-sat.dbg",
std::ios_base::trunc | std::ios_base::out);
out.exceptions(std::ifstream::failbit | std::ifstream::badbit);
@ -638,7 +639,7 @@ namespace spot
}
}
}
#if DEBUG
#if TRACE
dout << "--- transition variables ---\n";
for (unsigned i = 0; i < cand_size; ++i)
for (unsigned j = 0; j < alpha_size; ++j)

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2013, 2014, 2015, 2016, 2017 Laboratoire de Recherche
// Copyright (C) 2013-2018 Laboratoire de Recherche
// et Développement de l'Epita.
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <fstream>
#include <sstream>
#include <map>
@ -41,14 +42,14 @@
// file used to communicate with the sat solver will be left in
// the current directory.
//
// Additionally, if the following DEBUG macro is set to 1, the CNF
// Additionally, if the following TRACE macro is set to 1, the CNF
// file will be output with a comment before each clause, and an
// additional output file (dtwa-sat.dbg) will be created with a list
// of all positive variables in the result and their meaning.
#define DEBUG 0
#define TRACE 0
#if DEBUG
#if TRACE
#define dout out << "c "
#define cnf_comment(...) solver.comment(__VA_ARGS__)
#define trace std::cerr
@ -247,7 +248,7 @@ namespace spot
int
transid(unsigned src, bdd& cond, unsigned dst)
{
#if DEBUG
#if TRACE
try
{
return helper.get_t(src, alpha_map.at(cond), dst);
@ -272,7 +273,7 @@ namespace spot
int
transacc(unsigned src, bdd& cond, unsigned dst, unsigned nacc)
{
#if DEBUG
#if TRACE
try
{
return helper.get_ta(src, alpha_map.at(cond), dst, nacc);
@ -293,7 +294,7 @@ namespace spot
unsigned dst_ref, acc_cond::mark_t acc_cand = 0U,
acc_cond::mark_t acc_ref = 0U)
{
#if DEBUG
#if TRACE
try
{
return helper.get_p(
@ -315,7 +316,7 @@ namespace spot
#endif
}
#if DEBUG
#if TRACE
int
pathid(unsigned path, unsigned src_cand, unsigned dst_cand)
{
@ -539,7 +540,7 @@ namespace spot
bool state_based,
bool colored)
{
#if DEBUG
#if TRACE
debug_dict = ref->get_dict();
#endif
// Compute the AP used.
@ -572,7 +573,7 @@ namespace spot
// Empty automaton is impossible.
assert(d.cand_size > 0);
#if DEBUG
#if TRACE
debug_ref_acc = &ref->acc();
debug_cand_acc = &d.cacc;
solver.comment("d.ref_size:", d.ref_size, '\n');
@ -597,7 +598,7 @@ namespace spot
for (unsigned q1 = 0; q1 < d.cand_size; ++q1)
for (unsigned l = 0; l < alpha_size; ++l)
{
#if DEBUG
#if TRACE
solver.comment("");
for (unsigned q2 = 0; q2 < d.cand_size; ++q2)
{
@ -768,7 +769,7 @@ namespace spot
for (auto& v: missing)
{
#if DEBUG
#if TRACE
solver.comment((rejloop ?
"(11) " : "(12) "), f_p,
"", d.fmt_t(q2, l, q3),
@ -787,7 +788,7 @@ namespace spot
orsep = " ";
}
solver.comment_rec(")\n");
#endif // DEBUG
#endif // TRACE
solver.add({-pid, -ti});
for (int s: v)
if (s < 0)
@ -825,7 +826,7 @@ namespace spot
q1, q1p, q3, dp, f2, f2p);
if (pid == p2id)
continue;
#if DEBUG
#if TRACE
solver.comment("(13) ", f_p, "",
d.fmt_t(q1, l, q3), "δ ");
@ -883,7 +884,7 @@ namespace spot
a->set_acceptance(satdict.cand_nacc, satdict.cand_acc);
a->new_states(satdict.cand_size);
#if DEBUG
#if TRACE
std::fstream out("dtwa-sat.dbg",
std::ios_base::trunc | std::ios_base::out);
out.exceptions(std::ifstream::failbit | std::ifstream::badbit);
@ -922,7 +923,7 @@ namespace spot
}
}
#if DEBUG
#if TRACE
dout << "--- transition variables ---\n";
for (unsigned i = 0; i < satdict.cand_size; ++i)
for (unsigned j = 0; j < alpha_size; ++j)

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2017 Laboratoire de Recherche et Développement
// Copyright (C) 2017-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/misc/minato.hh>
#include <spot/twa/twagraph.hh>
#include <spot/twaalgos/alternation.hh>
@ -180,8 +181,8 @@ namespace spot
}
// Handles the dualization of a universal initial transition.
// In theory the transition would be split into several existential
// initial transitions, but since spot does not allow multiple initial
// In theory the transition would be split into several existential
// initial transitions, but since spot does not allow multiple initial
// states, we rather use a trick: We add a new initial state, and then
// copy all exiting transitions from each of the state of the universal
// initial transition.
@ -251,9 +252,9 @@ namespace spot
}
// Given the bdd representation b of a transition, adds destination states
// to s, and returns the marks on the transition. s being empty means the
// to s, and returns the marks on the transition. s being empty means the
// transition goes toward a "forever true" state. s with size one
// represents an existential transition, while size over one represents
// represents an existential transition, while size over one represents
// a universal transition.
acc_cond::mark_t bdd_to_state(bdd b, std::vector<unsigned>& s)
{

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2009, 2011-2017 Laboratoire de Recherche et
// Copyright (C) 2009, 2011-2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
// Copyright (C) 2004, 2005 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
@ -20,6 +20,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/>.
#include "config.h"
#include <sstream>
#include <memory>
#include <spot/twaalgos/emptiness.hh>

View file

@ -1,6 +1,6 @@
## -*- coding: utf-8 -*-
## Copyright (C) 2011, 2013, 2014, 2016 Laboratoire de Recherche et
## Developpement de l'Epita (LRDE).
## Copyright (C) 2011, 2013, 2014, 2016, 2018 Laboratoire de Recherche
## et Developpement de l'Epita (LRDE).
## Copyright (C) 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
## département Systèmes Répartis Coopératifs (SRC), Université Pierre
## et Marie Curie.
@ -20,7 +20,8 @@
## You should have received a copy of the GNU General Public License
## along with this program. If not, see <http://www.gnu.org/licenses/>.
AM_CPPFLAGS = -I$(top_builddir) -I$(top_srcdir) $(BUDDY_CPPFLAGS)
AM_CPPFLAGS = -I$(top_builddir) -I$(top_srcdir) $(BUDDY_CPPFLAGS) \
-I$(top_builddir)/lib -I$(top_srcdir)/lib
AM_CXXFLAGS = $(WARNING_CXXFLAGS)
gtecdir = $(pkgincludedir)/twaalgos/gtec

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2010, 2011, 2013, 2014, 2015, 2016 Laboratoire de
// Copyright (C) 2010-2011, 2013-2016, 2018 Laboratoire de
// Recherche et Développement de l'Epita (LRDE).
// Copyright (C) 2004, 2005 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
@ -20,6 +20,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/>.
#include "config.h"
#include <spot/twaalgos/gtec/ce.hh>
#include <spot/twaalgos/bfssteps.hh>
#include <spot/misc/hash.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2008, 2011, 2014, 2015, 2016 Laboratoire de Recherche
// Copyright (C) 2008, 2011, 2014-2016, 2018 Laboratoire de Recherche
// et Développement de l'Epita (LRDE).
// Copyright (C) 2003, 2004, 2005, 2006 Laboratoire d'Informatique de
// Paris 6 (LIP6), département Systèmes Répartis Coopératifs (SRC),
@ -22,6 +22,7 @@
// #define TRACE
#include "config.h"
#include <iostream>
#ifdef TRACE
#define trace std::cerr

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2014 Laboratoire de Recherche et Developpement de
// Copyright (C) 2014, 2018 Laboratoire de Recherche et Developpement de
// l'Epita (LRDE).
// Copyright (C) 2004, 2005 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
@ -20,6 +20,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/>.
#include "config.h"
#include <spot/twaalgos/gtec/sccstack.hh>
namespace spot

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2014, 2016 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
// Copyright (C) 2014, 2016, 2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
// Copyright (C) 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
// et Marie Curie.
@ -20,6 +20,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/>.
#include "config.h"
#include <ostream>
#include <spot/twaalgos/gtec/status.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2008, 2010, 2011, 2013-2017 Laboratoire de
// Copyright (C) 2008, 2010, 2011, 2013-2018 Laboratoire de
// recherche et développement de l'Epita (LRDE).
// Copyright (C) 2004, 2005 Laboratoire d'Informatique de Paris 6
// (LIP6), département Systèmes Répartis Coopératifs (SRC), Université
@ -22,6 +22,7 @@
//#define TRACE
#include "config.h"
#include <iostream>
#ifdef TRACE
#define trace std::cerr

View file

@ -1,9 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2011, 2012, 2014, 2015, 2016, 2017 Laboratoire de Recherche et
// Copyright (C) 2014-2018 Laboratoire de Recherche et
// Developpement de l'Epita (LRDE).
// Copyright (C) 2003, 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
// et Marie Curie.
//
// This file is part of Spot, a model checking library.
//
@ -20,6 +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/>.
#include "config.h"
#include <ostream>
#include <sstream>
#include <cstring>

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2017 Laboratoire de Recherche et Développement de l'Epita
// (LRDE).
// Copyright (C) 2017-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
//
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/iscolored.hh>
namespace spot

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2012-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2012-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/isdet.hh>
#include <spot/twaalgos/sccinfo.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2013, 2015-2017 Laboratoire de Recherche et
// Copyright (C) 2013, 2015-2018 Laboratoire de Recherche et
// Developpement de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/isunamb.hh>
#include <spot/twaalgos/product.hh>
#include <spot/twaalgos/sccinfo.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2012-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2012-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/tl/formula.hh>
#include <spot/twaalgos/isweakscc.hh>
#include <spot/twaalgos/mask.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2016, 2017 Laboratoire de Recherche et Développement
// Copyright (C) 2016-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <numeric>
#include <spot/twa/twa.hh>
#include <spot/twaalgos/dualize.hh>

View file

@ -1,9 +1,9 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2011, 2012, 2013, 2014, 2015, 2016 Laboratoire de
// Recherche et Développement de l'Epita (LRDE).
// Copyright (C) 2003, 2004, 2005 Laboratoire d'Informatique de Paris
// 6 (LIP6), département Systèmes Répartis Coopératifs (SRC),
// Université Pierre et Marie Curie.
// Copyright (C) 2011-2016, 2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
// Copyright (C) 2003-2005 Laboratoire d'Informatique de Paris 6
// (LIP6), département Systèmes Répartis Coopératifs (SRC), Université
// Pierre et Marie Curie.
//
// This file is part of Spot, a model checking library.
//
@ -20,6 +20,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/>.
#include "config.h"
#include <spot/twaalgos/lbtt.hh>
#include <map>
#include <string>

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2009, 2010, 2012, 2013, 2014, 2015, 2016 Laboratoire
// de Recherche et Développement de l'Epita (LRDE).
// Copyright (C) 2009-2010, 2012-2016, 2018 Laboratoire de Recherche
// et Développement de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
//
@ -17,6 +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/>.
#include "config.h"
#include <utility>
#include <algorithm>
#include <spot/tl/unabbrev.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2008-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2008-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
// Copyright (C) 2003-2006 Laboratoire d'Informatique de Paris 6
// (LIP6), département Systèmes Répartis Coopératifs (SRC), Université
@ -20,6 +20,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/>.
#include "config.h"
#include <spot/misc/hash.hh>
#include <spot/misc/bddlt.hh>
#include <spot/misc/minato.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2011, 2013-2017 Laboratoire de recherche et
// Copyright (C) 2011, 2013-2018 Laboratoire de recherche et
// développement de l'Epita (LRDE).
// Copyright (C) 2004, 2005 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
@ -22,6 +22,7 @@
//#define TRACE
#include "config.h"
#include <iostream>
#ifdef TRACE
#define trace std::cerr

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2015, 2016, 2017 Laboratoire de Recherche et Développement
// Copyright (C) 2015-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/mask.hh>
namespace spot

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2010-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2010-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -19,13 +19,13 @@
//#define TRACE
#ifdef TRACE
# define trace std::cerr
#else
# define trace while (0) std::cerr
#endif
#include "config.h"
#include <queue>
#include <deque>
#include <set>

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2009, 2011, 2012, 2014, 2015, 2016 Laboratoire de
// Recherche et Développement de l'Epita (LRDE).
// Copyright (C) 2009, 2011, 2012, 2014-2016, 2018 Laboratoire
// de Recherche et Développement de l'Epita (LRDE).
// Copyright (C) 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
// et Marie Curie.
@ -20,6 +20,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/>.
#include "config.h"
#include <ostream>
#include <sstream>
#include <spot/twaalgos/neverclaim.hh>

View file

@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/parity.hh>
#include <spot/twa/twagraph.hh>
#include <spot/twaalgos/product.hh>

View file

@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/postproc.hh>
#include <spot/twaalgos/minimize.hh>
#include <spot/twaalgos/simulation.hh>

View file

@ -20,6 +20,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/>.
#include "config.h"
#include <set>
#include <iterator>
#include <vector>

View file

@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/product.hh>
#include <spot/twa/twagraph.hh>
#include <spot/twaalgos/complete.hh>

View file

@ -1,5 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2017-2018 Laboratoire de Recherche et Développement de l'Epita.
// Copyright (C) 2017-2018 Laboratoire de Recherche et Développement
// de l'Epita.
//
// This file is part of Spot, a model checking library.
//
@ -16,10 +17,9 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "config.h"
#include <deque>
#include <spot/twaalgos/rabin2parity.hh>
#include <spot/twaalgos/sccinfo.hh>
namespace spot

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2008-2010, 2012-2017 Laboratoire de Recherche et
// Copyright (C) 2008-2010, 2012-2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
// Copyright (C) 2004, 2005, 2007 Laboratoire d'Informatique de
// Paris 6 (LIP6), département Systèmes Répartis Coopératifs (SRC),
@ -20,6 +20,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/>.
#include "config.h"
#include <spot/twaalgos/randomgraph.hh>
#include <spot/twa/twagraph.hh>
#include <spot/misc/random.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2014-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2014-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <algorithm>
#include <numeric>
#include <random>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2009, 2011, 2013, 2014, 2015, 2016 Laboratoire de Recherche
// Copyright (C) 2009, 2011, 2013-2016, 2018 Laboratoire de Recherche
// et Développement de l'Epita (LRDE).
// Copyright (C) 2003, 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
@ -20,6 +20,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/>.
#include "config.h"
#include <cassert>
#include <spot/twaalgos/reachiter.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2015, 2016, 2017 Laboratoire de Recherche et Développement
// Copyright (C) 2015-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/relabel.hh>
#include <spot/twa/formula2bdd.hh>

View file

@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/remfin.hh>
#include <spot/twaalgos/sccinfo.hh>
#include <iostream>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2015-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2015-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/remprop.hh>
#include <spot/twaalgos/mask.hh>
#include <spot/misc/casts.hh>
@ -124,7 +125,7 @@ namespace spot
twa_graph_ptr remove_ap::strip(const_twa_graph_ptr aut) const
{
bdd restrict = bddtrue;
bdd restrict_ = bddtrue;
bdd exist = bddtrue;
auto d = aut->get_dict();
@ -147,7 +148,7 @@ namespace spot
int v = d->has_registered_proposition(ap, aut);
if (v >= 0)
{
restrict &= bdd_ithvar(v);
restrict_ &= bdd_ithvar(v);
res->unregister_ap(v);
}
}
@ -156,7 +157,7 @@ namespace spot
int v = d->has_registered_proposition(ap, aut);
if (v >= 0)
{
restrict &= bdd_nithvar(v);
restrict_ &= bdd_nithvar(v);
res->unregister_ap(v);
}
}
@ -165,7 +166,7 @@ namespace spot
acc_cond::mark_t&, unsigned)
{
cond = bdd_restrict(bdd_exist(cond, exist),
restrict);
restrict_);
});
return res;
}

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2015-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2015-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <vector>
#include <map>
#include <utility>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2009-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2009-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/sccfilter.hh>
#include <spot/twaalgos/reachiter.hh>
#include <spot/twaalgos/sccinfo.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2014-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2014-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/sccinfo.hh>
#include <stack>
#include <algorithm>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2011, 2013-2017 Laboratoire de Recherche et
// Copyright (C) 2011, 2013-2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
// Copyright (C) 2004, 2005 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
@ -22,6 +22,7 @@
//#define TRACE
#include "config.h"
#include <iostream>
#ifdef TRACE
#define trace std::cerr

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2015, 2016, 2017 Laboratoire de Recherche et
// Copyright (C) 2015-2018 Laboratoire de Recherche et
// Développement de l'Epita.
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/sepsets.hh>
#include <spot/twaalgos/sccinfo.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2012-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2012-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <queue>
#include <map>
#include <utility>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2017 Laboratoire de Recherche et Développement
// Copyright (C) 2017-2018 Laboratoire de Recherche et Développement
// de l'Epita.
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/split.hh>
namespace spot

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2008, 2011, 2012, 2013, 2014, 2015, 2016, 2017
// Laboratoire de Recherche et Développement de l'Epita (LRDE).
// Copyright (C) 2008, 2011-2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
// Copyright (C) 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
// et Marie Curie.
@ -20,6 +20,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/>.
#include "config.h"
#include <iostream>
#include <sstream>
#include <spot/twa/twa.hh>

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2010, 2011, 2013, 2014, 2015, 2016, 2017 Laboratoire
// de Recherche et Développement de l'Epita (LRDE)
// Copyright (C) 2010-2011, 2013-2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE)
//
// This file is part of Spot, a model checking library.
//
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/strength.hh>
#include <spot/misc/hash.hh>
#include <spot/twaalgos/isweakscc.hh>

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2012, 2014, 2015, 2017 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
// Copyright (C) 2012, 2014-2015, 2017-2018 Laboratoire de Recherche
// et Développement de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
//
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/stripacc.hh>
#include <spot/twaalgos/reachiter.hh>

View file

@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/stutter.hh>
#include <spot/twa/twa.hh>
#include <spot/misc/hash.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2017 Laboratoire de Recherche et Développement
// Copyright (C) 2017, 2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/alternation.hh>
#include <spot/twaalgos/sum.hh>
#include <spot/twa/twagraph.hh>
@ -76,7 +77,7 @@ namespace spot
}
}
// Helper function that perform the sum of the automaton in left and the
// Helper function that perform the sum of the automaton in left and the
// automaton in right, using is_sum true for sum_or and is_sum false
// as sum_and
static

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2011, 2013-2017 Laboratoire de Recherche et
// Copyright (C) 2011, 2013-2018 Laboratoire de Recherche et
// Developpement de l'Epita (LRDE).
// Copyright (C) 2004, 2005 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
@ -25,6 +25,7 @@
//#define TRACE
#include "config.h"
#include <iostream>
#ifdef TRACE
#define trace std::cerr

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2011, 2013-2017 Laboratoire de Recherche et
// Copyright (C) 2011, 2013-2018 Laboratoire de Recherche et
// Développement de l'Epita (LRDE).
// Copyright (C) 2004, 2005 Laboratoire d'Informatique de Paris 6 (LIP6),
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
@ -34,6 +34,7 @@
//#define TRACE
#include "config.h"
#include <iostream>
#ifdef TRACE
#define trace std::cerr

View file

@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/totgba.hh>
#include <spot/twaalgos/remfin.hh>
#include <spot/twaalgos/cleanacc.hh>
@ -25,11 +26,11 @@
#include <deque>
#include <tuple>
#define DEBUG 0
#if DEBUG
#define debug std::cerr
#define TRACE 0
#if TRACE
#define trace std::cerr
#else
#define debug while (0) std::cerr
#define trace while (0) std::cerr
#endif
namespace spot
@ -121,11 +122,11 @@ namespace spot
SPOT_UNREACHABLE();
}
}
#if DEBUG
debug << "\nPrinting all clauses\n";
#if TRACE
trace << "\nPrinting all clauses\n";
for (unsigned i = 0; i < all_clauses_.size(); ++i)
{
debug << i << " Fin:" << all_clauses_[i].first << " Inf:"
trace << i << " Fin:" << all_clauses_[i].first << " Inf:"
<< all_clauses_[i].second << '\n';
}
#endif
@ -238,16 +239,16 @@ namespace spot
res[scc].push_back(clause);
}
}
#if DEBUG
debug << "accepting clauses\n";
#if TRACE
trace << "accepting clauses\n";
for (unsigned i = 0; i < res.size(); ++i)
{
debug << "scc(" << i << ") --> ";
trace << "scc(" << i << ") --> ";
for (auto elt : res[i])
debug << elt << ',';
debug << '\n'
trace << elt << ',';
trace << '\n'
}
debug << '\n';
trace << '\n';
#endif
}
@ -257,7 +258,7 @@ namespace spot
void
add_state(unsigned st)
{
debug << "add_state(" << st << ")\n";
trace << "add_state(" << st << ")\n";
if (st_repr_[st].empty())
{
unsigned st_scc = si_.scc_of(st);
@ -270,7 +271,7 @@ namespace spot
else
st_repr_[st].emplace_back(-1U, res_->new_state());
debug << "added\n";
trace << "added\n";
}
}
@ -317,7 +318,7 @@ namespace spot
init_st_in_(in->get_init_state_number()),
init_reachable_(is_init_reachable())
{
debug << "State based ? " << state_based_ << '\n';
trace << "State based ? " << state_based_ << '\n';
std::tie(all_inf_, all_fin_) = code.used_inf_fin_sets();
split_dnf_clauses(code);
find_set_to_add();
@ -346,7 +347,7 @@ namespace spot
add_state(st);
for (const auto& e : in_->out(st))
{
debug << "working_on_edge(" << st << ',' << e.dst << ")\n";
trace << "working_on_edge(" << st << ',' << e.dst << ")\n";
unsigned dst_scc = si_.scc_of(e.dst);
if (!si_.is_useful_scc(dst_scc))
@ -366,7 +367,7 @@ namespace spot
for (const auto& p_src : st_repr_[st])
for (const auto& p_dst : st_repr_[e.dst])
{
debug << "repr(" << p_src.second << ','
trace << "repr(" << p_src.second << ','
<< p_dst.second << ")\n";
if (same_scc && p_src.first == p_dst.first)

View file

@ -17,6 +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/>.
#include "config.h"
#include <spot/misc/bddlt.hh>
#include <spot/misc/minato.hh>
#include <spot/twa/twagraph.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2013-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2013-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/translate.hh>
#include <spot/twaalgos/ltl2tgba_fm.hh>
#include <spot/twaalgos/compsusp.hh>

View file

@ -1,5 +1,5 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2013-2017 Laboratoire de Recherche et Développement
// Copyright (C) 2013-2018 Laboratoire de Recherche et Développement
// de l'Epita (LRDE).
//
// This file is part of Spot, a model checking library.
@ -17,6 +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/>.
#include "config.h"
#include <spot/twaalgos/word.hh>
#include <spot/twa/bddprint.hh>
#include <spot/twa/bdddict.hh>