Deprecate reduce() in favor of ltl_simplifier.

* src/ltlvisit/reduce.hh: Mark the file as obsolete.
(reduce): Declare this function as obsolete.
* src/ltlvisit/reduce.cc: Define SKIP_DEPRECATED_WARNING
so we can include reduce.hh.
* src/sanity/includes.test: Also use SKIP_DEPRECATED_WARNING
when compiling headers.
* iface/dve2/dve2check.cc,
src/ltltest/equals.cc, src/ltltest/randltl.cc,
src/ltltest/reduc.cc, src/tgbaalgos/ltl2tgba_fm.hh,
src/tgbaalgos/ltl2tgba_fm.cc, src/tgbatest/randtgba.cc,
wrap/python/ajax/spot.in, wrap/python/spot.i: Adjust
to use ltl_simplifier.
* src/tgbatest/ltl2tgba.cc: Adjust to use ltl_simplifier,
and replace -fr1...-fr7 options by a single -fr option.
* src/tgbatest/spotlbtt.test: Adjust -fr flags accordingly.
* src/tgbatest/reductgba.cc: Do not include reduce.hh.
This commit is contained in:
Alexandre Duret-Lutz 2011-08-24 19:16:15 +02:00
parent c0085a8f30
commit 67f4e8b5ce
15 changed files with 367 additions and 166 deletions

View file

@ -334,18 +334,22 @@ if not f:
finish()
# Formula simplifications
opt = spot.Reduce_None
simpopt = spot.ltl_simplifier_options(False, False, False, False, False)
dored = False
for r in form.getlist('r'):
dored = True
if r == 'br':
opt = opt + spot.Reduce_Basics
simpopt.reduce_basics = True
elif r == 'si':
opt = opt + spot.Reduce_Syntactic_Implications
simpopt.synt_impl = True
elif r == 'eu':
opt = opt + spot.Reduce_Eventuality_And_Universality
simpopt.event_univ = True
elif r == 'lc':
opt = opt + spot.Reduce_Containment_Checks_Stronger
if opt != spot.Reduce_None:
f2 = spot.reduce(f, opt)
simpopt.containment_checks = True
simpopt.containment_checks_stronger = True
if dored:
simp = spot.ltl_simplifier(simpopt)
f2 = simp.simplify(f)
f.destroy()
f = f2

View file

@ -66,7 +66,7 @@
#include "ltlvisit/dump.hh"
#include "ltlvisit/lunabbrev.hh"
#include "ltlvisit/nenoform.hh"
#include "ltlvisit/reduce.hh"
#include "ltlvisit/simplify.hh"
#include "ltlvisit/tostring.hh"
#include "ltlvisit/tunabbrev.hh"
@ -164,7 +164,7 @@ using namespace spot;
%include "ltlvisit/dump.hh"
%include "ltlvisit/lunabbrev.hh"
%include "ltlvisit/nenoform.hh"
%include "ltlvisit/reduce.hh"
%include "ltlvisit/simplify.hh"
%include "ltlvisit/tostring.hh"
%include "ltlvisit/tunabbrev.hh"