Deprecate ltl::destroy(f) in favor of f->destroy()
* src/ltlast/formula.cc, src/ltlast/formula.hh (formula::clone): Transform this static function into a member function. * src/ltlvisit/destroy.hh (destroy): Document and declare as deprecated. * bench/split-product/cutscc.cc, iface/gspn/ltlgspn.cc, src/eltlparse/eltlparse.yy, src/eltltest/acc.cc, src/evtgbaalgos/tgba2evtgba.cc, src/evtgbatest/ltl2evtgba.cc, src/ltlast/automatop.cc, src/ltlast/binop.cc, src/ltlast/multop.cc, src/ltlast/unop.cc, src/ltlenv/declenv.cc, src/ltlenv/declenv.hh, src/ltlparse/ltlparse.yy, src/ltltest/equals.cc, src/ltltest/randltl.cc, src/ltltest/readltl.cc, src/ltltest/reduc.cc, src/ltltest/syntimpl.cc, src/ltltest/tostring.cc, src/ltlvisit/destroy.cc src/ltlvisit/basicreduce.cc, src/ltlvisit/contain.cc, src/ltlvisit/reduce.cc, src/ltlvisit/syntimpl.cc, src/tgba/bdddict.cc, src/tgba/bddprint.cc, src/tgba/taa.cc, src/tgba/tgbabddconcretefactory.cc, src/tgba/tgbaexplicit.cc, src/tgba/tgbafromfile.cc, src/tgbaalgos/eltl2tgba_lacim.cc, src/tgbaalgos/ltl2taa.cc, src/tgbaalgos/ltl2tgba_fm.cc, src/tgbaalgos/ltl2tgba_lacim.cc, src/tgbaalgos/neverclaim.cc, src/tgbaalgos/randomgraph.cc, src/tgbaparse/tgbaparse.yy, src/tgbatest/complementation.cc, src/tgbatest/eltl2tgba.cc, src/tgbatest/ltl2tgba.cc, src/tgbatest/ltlprod.cc, src/tgbatest/mixprod.cc, src/tgbatest/randtgba.cc, src/tgbatest/reductgba.cc, wrap/python/cgi/ltl2tgba.in, wrap/python/tests/ltl2tgba.py, wrap/python/tests/ltlparse.py, wrap/python/tests/ltlsimple.py: Adjust destroy() usage, and remove the #include "destroy.hh" when appropriate.
This commit is contained in:
parent
48fb19ea44
commit
77df39b4dd
53 changed files with 260 additions and 259 deletions
|
|
@ -22,7 +22,6 @@
|
|||
#include <ostream>
|
||||
#include <sstream>
|
||||
#include <cassert>
|
||||
#include <ltlvisit/destroy.hh>
|
||||
#include <ltlvisit/tostring.hh>
|
||||
#include <ltlvisit/tostring.hh>
|
||||
#include <ltlast/atomic_prop.hh>
|
||||
|
|
@ -156,7 +155,7 @@ namespace spot
|
|||
ltl::atomic_prop::instance(s.str(),
|
||||
ltl::default_environment::instance());
|
||||
int res = register_acceptance_variable(f, for_me);
|
||||
ltl::destroy(f);
|
||||
f->destroy();
|
||||
return res;
|
||||
}
|
||||
|
||||
|
|
@ -278,7 +277,7 @@ namespace spot
|
|||
// formula itself.
|
||||
release_variables(var, n);
|
||||
if (f)
|
||||
ltl::destroy(f);
|
||||
f->destroy();
|
||||
var_refs.erase(cur);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
// Copyright (C) 2003, 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
|
||||
// Copyright (C) 2003, 2004, 2009 Laboratoire d'Informatique de Paris 6 (LIP6),
|
||||
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
|
||||
// et Marie Curie.
|
||||
//
|
||||
|
|
@ -25,7 +25,6 @@
|
|||
#include "bddprint.hh"
|
||||
#include "ltlvisit/tostring.hh"
|
||||
#include "formula2bdd.hh"
|
||||
#include "ltlvisit/destroy.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
|
|
@ -202,7 +201,7 @@ namespace spot
|
|||
{
|
||||
const ltl::formula* f = bdd_to_formula(b, d);
|
||||
to_string(f, os);
|
||||
destroy(f);
|
||||
f->destroy();
|
||||
return os;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -23,7 +23,6 @@
|
|||
#include <algorithm>
|
||||
#include <iterator>
|
||||
#include <iostream>
|
||||
#include "ltlvisit/destroy.hh"
|
||||
#include "tgba/formula2bdd.hh"
|
||||
#include "misc/bddop.hh"
|
||||
#include "taa.hh"
|
||||
|
|
@ -99,7 +98,7 @@ namespace spot
|
|||
taa::add_condition(transition* t, const ltl::formula* f)
|
||||
{
|
||||
t->condition &= formula_to_bdd(f, dict_, this);
|
||||
ltl::destroy(f);
|
||||
f->destroy();
|
||||
}
|
||||
|
||||
void
|
||||
|
|
@ -125,7 +124,7 @@ namespace spot
|
|||
|
||||
bdd_dict::fv_map::iterator i = dict_->acc_map.find(f);
|
||||
assert(i != dict_->acc_map.end());
|
||||
ltl::destroy(f);
|
||||
f->destroy();
|
||||
bdd v = bdd_ithvar(i->second);
|
||||
t->acceptance_conditions |= v & bdd_exist(neg_acceptance_conditions_, v);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -19,8 +19,8 @@
|
|||
// Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||
// 02111-1307, USA.
|
||||
|
||||
#include "ltlvisit/destroy.hh"
|
||||
#include "tgbabddconcretefactory.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
tgba_bdd_concrete_factory::tgba_bdd_concrete_factory(bdd_dict* dict)
|
||||
|
|
@ -32,7 +32,7 @@ namespace spot
|
|||
{
|
||||
acc_map_::iterator ai;
|
||||
for (ai = acc_.begin(); ai != acc_.end(); ++ai)
|
||||
destroy(ai->first);
|
||||
ai->first->destroy();
|
||||
get_dict()->unregister_all_my_variables(this);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
// Copyright (C) 2003, 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
|
||||
// Copyright (C) 2003, 2004, 2009 Laboratoire d'Informatique de Paris 6 (LIP6),
|
||||
// département Systèmes Répartis Coopératifs (SRC), Université Pierre
|
||||
// et Marie Curie.
|
||||
//
|
||||
|
|
@ -21,7 +21,6 @@
|
|||
|
||||
#include "ltlast/atomic_prop.hh"
|
||||
#include "ltlast/constant.hh"
|
||||
#include "ltlvisit/destroy.hh"
|
||||
#include "tgbaexplicit.hh"
|
||||
#include "tgba/formula2bdd.hh"
|
||||
#include "misc/bddop.hh"
|
||||
|
|
@ -187,7 +186,7 @@ namespace spot
|
|||
tgba_explicit::add_condition(transition* t, const ltl::formula* f)
|
||||
{
|
||||
t->condition &= formula_to_bdd(f, dict_, this);
|
||||
ltl::destroy(f);
|
||||
f->destroy();
|
||||
}
|
||||
|
||||
void
|
||||
|
|
@ -201,7 +200,7 @@ namespace spot
|
|||
tgba_explicit::declare_acceptance_condition(const ltl::formula* f)
|
||||
{
|
||||
int v = dict_->register_acceptance_variable(f, this);
|
||||
ltl::destroy(f);
|
||||
f->destroy();
|
||||
bdd neg = bdd_nithvar(v);
|
||||
neg_acceptance_conditions_ &= neg;
|
||||
|
||||
|
|
@ -287,7 +286,7 @@ namespace spot
|
|||
/* If this second assert fails and the first doesn't,
|
||||
things are badly broken. This has already happened. */
|
||||
assert(i != dict_->acc_map.end());
|
||||
ltl::destroy(f);
|
||||
f->destroy();
|
||||
bdd v = bdd_ithvar(i->second);
|
||||
v &= bdd_exist(neg_acceptance_conditions_, v);
|
||||
return v;
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@
|
|||
|
||||
#include "tgba/public.hh"
|
||||
#include "tgbafromfile.hh"
|
||||
#include "ltlvisit/destroy.hh"
|
||||
|
||||
namespace spot
|
||||
{
|
||||
|
|
@ -56,7 +55,7 @@ namespace spot
|
|||
{
|
||||
if (f_)
|
||||
{
|
||||
ltl::destroy(f_);
|
||||
f_->destroy();
|
||||
f_ = 0;
|
||||
}
|
||||
std::string line = "";
|
||||
|
|
@ -94,4 +93,3 @@ namespace spot
|
|||
return formula_;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue