Commit graph

57 commits

Author SHA1 Message Date
Alexandre Duret-Lutz
de295e4632 python: fix a memory leak in all added __iter__ methods
Reported by Yechuan Xia

* python/spot/impl.i: Add %newobject to all __iter__ methods.
* NEWS: Mention the list of affected methods.
* THANKS: Update.
2022-02-01 12:04:01 +01:00
Alexandre Duret-Lutz
480289867f sccinfo: fix accepting run computation
* spot/twaalgos/sccinfo.cc (scc_info::get_accepting_run): Ignore edges
whose colors are not part of the colors gathered in the SCC up to
deciding acceptance.
* tests/python/genem.py: New test case, reported by Clément Tamines.
* THANKS: Add him.
* NEWS: Mention the bug.
2022-01-14 20:29:10 +01:00
Alexandre Duret-Lutz
0b048e1c05 twagraph: improve doc
Based on report by Michaël Cadilhac.

* spot/graph/graph.hh, spot/twa/twagraph.hh (defrag_state): Clarify
that only unreachable states are meant to be removed.
* spot/twa/twagraph.hh (merge_edges): Typo in comment.  Fixes #454.
* THANKS: Add Michaël.
2021-02-18 22:19:03 +01:00
Alexandre Duret-Lutz
eeaed5592f fix ignored aborter in WDBA-minimization
Fixes #443, reported by Roei Nahum.  (However the fix
only works for the development version, where wdba-det-max
was introduced to work around that kind of problem.)

* spot/twaalgos/minimize.cc: Avoid aborter being implicitly
converted to Boolean.
* tests/core/ltl2tgba2.test: Add test case.
* THANKS: Add Roei Nahum.
2020-12-08 12:03:30 +01:00
Alexandre Duret-Lutz
67fa19cb08 relabel: generalize 9365f8de1 to remove more false edges
* spot/twaalgos/relabel.cc: Detect false edges as they are created,
even as the result of multiple renamings.
* tests/core/ltl2tgba2.test: More test cases, reported by Jens Kreber.
* NEWS: Mention the bug.
* THANKS: Add Jens.
2020-04-10 10:52:40 +02:00
Alexandre Duret-Lutz
d2ba554507 tmpfile: improve error message
* spot/misc/tmpfile.cc: Display strerror(errno) plus some suggestions
that depend on the error.  Based on a report from Shengping Shaw.
* THANKS: Add reporter.
* tests/core/ltlcross5.test: New file.
* tests/Makefile.am: Add it.
2019-12-15 17:44:54 +01:00
Alexandre Duret-Lutz
be389c5c25 introduce op::strong_X
This was prompted by reports by Andrew Wells and Yong Li.

* NEWS, doc/tl/tl.tex: Document the changes.
* THANKS: Add Andrew.
* bin/ltlfilt.cc: Match --ltl before --from-ltlf if needed.
* spot/parsetl/parsedecl.hh, spot/parsetl/parsetl.yy,
spot/parsetl/scantl.ll: Parse X[!].
* spot/tl/formula.cc, spot/tl/formula.hh: Declare the new operator.
* spot/tl/ltlf.cc: Adjust to handle op::X and op::strong_X correctly.
* spot/tl/dot.cc, spot/tl/mark.cc, spot/tl/mutation.cc,
spot/tl/print.cc, spot/tl/simplify.cc, spot/tl/snf.cc,
spot/tl/unabbrev.cc, spot/twa/formula2bdd.cc,
spot/twaalgos/ltl2taa.cc, spot/twaalgos/ltl2tgba_fm.cc,
tests/core/ltlgrind.test, tests/core/rand.test,
tests/core/sugar.test, tests/python/randltl.ipynb: Adjust.
* tests/core/ltlfilt.test, tests/core/sugar.test,
tests/core/utf8.test: More tests.
2019-09-23 17:01:28 +02:00
Alexandre Duret-Lutz
57e6208e1e Update instructions for divine-ltsmin installation
* tests/ltsmin/README: Here.
* THANKS: Reported by Jiraphapa Jiravaraphan.
2019-06-04 13:58:19 +02:00
Alexandre Duret-Lutz
7d6bfe545f remprop: reset no-terminal property
Reported by Yong Li.

* spot/twaalgos/remprop.cc: Here.
* tests/python/removeap.py: New test case.
* tests/Makefile.am: Add it.
* NEWS: Document the issue.
* THANKS: Add Yong Li.
2019-06-04 13:58:19 +02:00
Alexandre Duret-Lutz
ba89cb5db5 * THANKS: Add Victor Khomenko. 2019-04-26 23:01:43 +02:00
Alexandre Duret-Lutz
7e3232e3a3 org: explain how to build automata with state-based acceptance
* doc/org/tut22.org: Here.  Suggested by Yannick Molinghen.
* THANKS: Add him.
2019-04-03 10:48:04 +02:00
Alexandre Duret-Lutz
1d0db88073 org: suggest python-dev for installing Python headers
* doc/org/install.org: Mention python-dev and libpython3-dev.
Suggested by Tereza Šťastná.
* THANKS: Add her.
2019-04-02 23:18:27 +02:00
Alexandre Duret-Lutz
f26dd904ff python: better support for explicit Kripke
Part of issue #376, reported by Hashim Ali.

* python/spot/impl.i: Add bindings for kripke_graph.
* python/spot/__init__.py (automaton): Add a want_kripke option.
* spot/kripke/kripkegraph.hh: Honnor the "state-names" property
when displaying states.
* spot/twaalgos/hoa.cc: Preserve names of Kripke states.
* tests/python/ltsmin-dve.ipynb: Illustrate all the above.
* NEWS: Mention those changes.
* THANKS: Add Hashim.
2019-02-13 17:47:53 +01:00
Alexandre Duret-Lutz
188d210521 python: suggest installing GraphViz when dot is not found
This fixes an issue mentioned in #375.

* python/spot/aux.py (str_to_svg): Catch a missing 'dot' and instruct
the user to install GraphViz.
* THANKS: Add reporter.
2019-01-25 23:16:46 +01:00
Alexandre Duret-Lutz
ff960ee313 * THANKS: Add the reporter of #372. 2019-01-23 11:05:36 +01:00
Alexandre Duret-Lutz
365fde8364 org: typo
* doc/org/concepts.org: Typo reported by Paul Guénézan.
* THANKS: Add him.
2019-01-07 11:26:45 +01:00
Alexandre Duret-Lutz
6cfdf02c5a Fix Alpine Linux builds
Reported by Maxime Bouton.

* spot/misc/tmpfile.cc: Include stdlib.h, not cstdlib, so
that our replacement secure_getenv() is found.
* THANKS: Add Maxime.
2018-11-10 12:48:11 +01:00
Alexandre Duret-Lutz
250e121a60 print_dot: add xlabel to colored states if too many colors in use
Based on a report from Andreas Tollkötter.

* spot/twaalgos/dot.cc (highlight_states_show_num_): New option,
turned on implicitly when more than 8 colors are used.
* tests/core/highlightstate.test: Test it.
* NEWS: Mention it.
* THANKS: Add Andreas.
2018-09-25 14:04:11 +02:00
Alexandre Duret-Lutz
55dfbc8206 fix --disable-doxygen and --disable-c++17
Reported by Yuri Victorovich.

* configure.ac (enable_doxygen, enable_c++17): Use $enableval instead
of "yes".
* THANKS: Add Yuri.
2018-08-11 17:33:53 +02:00
Alexandre Duret-Lutz
568a6180f1 is_unambiguous: fix false negatives
Reported by Simon Jantsch and David Müller.

* tests/core/unambig.test: Test the issue.
* spot/twaalgos/isunamb.cc: Fix it.
* NEWS: Mention it.
* THANKS: Add Simon.
2018-04-09 10:22:49 +02:00
Alexandre Duret-Lutz
69a3e8486e stutter: fix closure() on Fin-acceptance
From a report by Anton Pirogov.

* NEWS: Mention the bug.
* spot/twaalgos/stutter.cc: Fix it.
* tests/core/stutter-tgba.test: Test it.
* THANKS: Add Anton.
2018-03-23 18:51:00 +01:00
Alexandre Duret-Lutz
183ec1fb4e ltlcross, autcross, ltldo: support --fail-on-timeout
Suggested by Tobias Meggendorfer.  Fixes #294.

* bin/autcross.cc, bin/ltlcross.cc, bin/ltldo.cc: Add the option.
* tests/core/autcross3.test, tests/core/ltlcross3.test,
tests/core/ltldo.test: Test it.
* tests/Makefile.am: Add autcross3.test.
* NEWS, doc/org/autcross.org, doc/org/ltlcross.org, doc/org/ltldo.org:
Mention the option.
* THANKS: Add Tobias.
2017-10-15 12:22:15 +02:00
Alexandre Duret-Lutz
002e6ed96b formula: fix building of {a->c[*]}
Fixes #285, reported by Florian Perlié-Long.

* NEWS: Mention the issue.
* spot/tl/formula.cc: Fix it.
* tests/core/kind.test: Document it.
* THANKS: Add Florian.
2017-09-26 17:32:54 +02:00
Alexandre Duret-Lutz
646c5170ed simplify: some new simplification rules
For #263, reported by Mikuláš Klokočka.

G(a & Xe1 & F(b & e2)) = G(a & e1 & Fb & e2)
F(a | Xu1 | G(b | u2)) = F(a | u1 | Gb | u2)

* spot/tl/simplify.cc: Implement the rules.
* doc/tl/tl.tex, NEWS: Document them.
* tests/core/reduccmp.test, tests/core/eventuniv.test: Add test cases.
* tests/core/det.test, tests/core/ltl2tgba2.test: Adjust to expect
smaller automata.
* THANKS: Add Mikuláš.
2017-09-02 11:27:04 +02:00
Alexandre Duret-Lutz
d2e9515c10 skip divine tests when divine does not understand compile --help
Fixes #235, reported by Henrich Lauko.

* python/spot/ltsmin.i: Catch CalledProcessError.
* NEWS: Mention the bug.
* THANKS: Add Henrich.
2017-02-28 17:02:06 +01:00
Alexandre Duret-Lutz
7574d6d1e2 debian: distribute static libraries
Suggested by Jeroen Meijer.

* debian/rules: Enable static libraries.
* debian/libbddx-dev.install, debian/libspot-dev.install: Distribute
them.
* THANKS: Add Jeroen.
* NEWS: Mention the change.
2017-01-14 09:29:32 +01:00
Alexandre Duret-Lutz
413eab1d32 ltlf: ensure alive holds initially
Reported by Shufang Zhu.

* spot/tl/ltlf.cc, spot/tl/ltlf.hh: Fix the transltion
and update the comments.
* tests/core/ltlfilt.test: Adjust test cases.
* NEWS: Mention the fix.
* THANKS: Add Shufang Zhu.
2016-12-09 21:37:15 +01:00
Alexandre Duret-Lutz
dd706d7847 twa: do not set prop_state_acc in set_acceptance
Reported by Juraj Major.

* spot/twa/twa.hh: check num_sets() in prop_state_acc() so we do not
have to set it in set_acceptance(), causing trouble if set_acceptance()
is called multiple times.
* tests/python/setacc.py: New test case.
* tests/Makefile.am: Add it.
* THANKS: Add Juraj.
* NEWS: Mention the bug.
2016-11-11 15:20:56 +01:00
Alexandre Duret-Lutz
d919b78c89 simulation: do not purge unreachable states when recording implications
This fixes the incorrect output of tgba_determinize() reported yesterday
by Reuben Rowe.

* spot/twaalgos/simulation.cc: Do not purge unreachable states when
recording implications.
* tests/python/bugdet.py: New test case.
* tests/Makefile.am: Add it.
* THANKS: Add Reuben.
* NEWS: Mention the bug.
2016-11-01 09:29:55 +01:00
Alexandre Duret-Lutz
421a9a1b12 relabel: do not unregister old AP that are also new
Reported by Ayrat Khalimov against the trans.html page when using
ltl3ba.

* spot/twaalgos/relabel.cc: Here.
* tests/core/ltl3dra.test: Test it.
* NEWS: Mention it.
* THANKS: Add Ayrat.
2016-07-07 15:57:14 +02:00
Amaury Fauchille
1c82444376 autfilt: add new option --accept-word
Suggested by Matthias Heizmann. Fixes #109.

* NEWS: notify the new option
* THANKS: add Matthias Heizmann
* bin/autfilt.cc: add new option --accept-word=WORD which filters
automata that accept WORD
* doc/org/autfilt.org: add an example of the new option
* tests/Makefile.am: add core/acc_word.test to the list of test files
* tests/core/acc_word.test: test some uses of the new option
2016-03-07 22:19:25 +01:00
Alexandre Duret-Lutz
1ca4204ccd Remove obsolete ACLOCAL_AMFLAGS definition.
Fixes #138, reported by Valentin Iovene.

* Makefile.am: Here.
* THANKS: Add Valentin.
2016-02-03 16:51:24 +01:00
Alexandre Duret-Lutz
cd8e53de09 is_unambiguous: fix detection of empty languages
* src/tests/unambig.test: New test case.  Reported by Ming-Hsien Tsai.
* src/twaalgos/sccfilter.cc: Always create an initial state.
* src/twaalgos/isunamb.cc: Speed up on empty languages.
* NEWS, THANKS: Update.
2015-10-20 08:06:31 +02:00
Alexandre Duret-Lutz
1f17b59360 debian: add licenses for lib/*
* debian/copyright: Here.
* THANKS: Add Michael, who reported the problem.
2015-08-26 18:27:15 +02:00
Alexandre Duret-Lutz
63969b13fa Fix spurious uniq.test failure.
Reported by Christopher Ziegler.

* src/tests/uniq.test: For LC_ALL=C before sort.
2015-08-23 17:38:30 +02:00
Alexandre Duret-Lutz
36a3dc45a7 configure: diagnose missing Python.h
Fixes #95, reported by Vitus Lam.

* m4/pypath.m4: Check for Python.h and print some advice if missing.
* NEWS: Mention this.
* THANKS: Add Vitus.
2015-06-30 21:37:03 +02:00
Alexandre Duret-Lutz
78e63d0324 nra2nba: Fix initial state construction.
This bug caused tgbatest/ltl2dstar.test to fail but because I had
no ltl2dstar on my computer for a while, I only discovered it after
David Müller and Joachim Klein reported a bug against ltlcross.
It might be the case that their bug is different (I can't reproduce it
using their format), but I hope it was caused by this as well.

* src/dstarparse/nra2nba.cc: Revert 57cda2d9, with a comment.
* THANKS: Add David.
2015-02-05 18:55:52 +01:00
Alexandre Duret-Lutz
e5124faa13 man: more doc about TGBA and monitors
This was prompted by an exchange of emails with Caroline Lemieux.

* src/bin/man/ltl2tgba.x: Add notes and references.
* NEWS, THANKS: Update.
2014-08-19 14:52:51 +02:00
Alexandre Duret-Lutz
17dd281b33 * doc/org/ltlfilt.org: Typo, reported by Fabrice Kordon. 2014-02-04 07:58:52 +01:00
Alexandre Duret-Lutz
ce6114f461 * THANKS: Jan should have been added earlier... 2013-07-29 00:25:13 +02:00
Alexandre Duret-Lutz
cb7bdf8c1f Fix interpretation of {e[*]} and !{e[*]}.
This follows from a discussion with Ernesto Posse.

The semantics for the {...} operator we use in Spot comes from the
cl(...) operator defined by Dax et al. (ATVA'09).  This is slightly
different from the the way the PSL spec interprets a SERE used in the
context of a temporal formula (appendix B.3.1.1.2, item 7).

cl({a;b}[*]) would match any infinite word that starts with a;b, while
in PSL {a;b}[*] would match any infinite word that alternates a and b.

Spot documents that {SERE} in a temporal formula is interpreted like
cl(SERE) however it failed to ignore the empty prefix of SERE.  So
{{a;b}[*]} would match anything, because the empty word is a prefix of
any word, and is also accepted by {a;b}[*].  Some trivial identities
and basic rewritings were also wrongly considering these empty
prefixes as well.

This patch therefore fixes the translation and syntactic
simplification rules, to really ignore these empty prefixes.

In some future version it should probably be wise to rename this {...}
operator as cl(...), and use {...} for the semantics given in appendix
B.3.1.1.2 (item 7) of the PSL specs.

* src/ltlast/unop.cc: Fix trivial identities.  We have
{[*0]} = 0 and !{[*0]} = 1.
* src/ltlvisit/simplify.cc: Fix basic rewriting rules.
{e[*]} = {e} and !{e[*]} = !{e}.
* doc/tl/tl.tex: Adjust documentation.
* doc/tl/tl.bib (dax.09.atva): New entry.
* src/tgbaalgos/ltl2tgba_fm.cc: Do not accept any
infinite word for {e[*]} just because the empty
prefix is matched by e[*].
* src/tgbatest/ltl2tgba.test: Add a test case.
* NEWS: Mention it.
* THANKS: Add Ernesto.
2013-07-29 00:25:13 +02:00
Alexandre Duret-Lutz
a9a96ee4ff ltlcross: do not use f after it has been destroyed.
Reported by Joachim Klein.

* src/bin/ltlcross.cc: Here.
* NEWS, THANKS: Update.
2013-07-09 14:00:49 +02:00
Alexandre Duret-Lutz
e2378b4904 Fix genltl --gh-r
Reported by František Blahoudek.

* src/bin/genltl.cc (R_n): Really generate (GFp1 || FGp2), not
(GFp1 || GFp2).
* NEWS: Mention the bug.
* THANKS: Update.
2013-04-30 00:01:35 +02:00
Alexandre Duret-Lutz
543de07737 Improve some Doxygen comments.
This follows up on a mail from Sonali Dutta.

* src/tgba/bdddict.hh (assert_emptiness, ~bdd_dict): Better
documentation.
* src/tgba/formula2bdd.hh (formula_to_bdd): Mention
unregister_all_my_variables().
(bdd_to_formula): Complete the documentation.
* THANKS: Add Sonali Dutta.
2013-02-20 12:04:35 +01:00
Alexandre Duret-Lutz
ebe2362bc9 Equip the LTL parser with printers for formulas and other token.
* src/ltlparse/ltlparse.yy: Add new printers.  Suggested by Akim
Demaille.
2012-05-10 10:23:13 +02:00
Alexandre Duret-Lutz
a2893520ca Properly thank Christian and Felix.
* THANKS, src/tgbaalgos/ltl2tgba_fm.cc: Here.
2012-05-07 14:44:50 +02:00
Alexandre Duret-Lutz
fdf8878db3 Update formulae.ltl not to use uncommon operators.
* bench/emptchk/formulae.ltl: Do not use + and * in the list of
formulas.  Use | and & instead.  The * operator was removed on
2010-01-30.  Reported by Étienne Renault.
2011-11-24 22:03:42 +01:00
Alexandre Duret-Lutz
ea6a1ffc22 Fully quote guards used by neverclaims.
Especially with should write !(p0) and not !p0, because p0 is
usually #define'd by the user and he may have forgotten to quote
the value of the macro.  This issue was discovered by Kristin
Yvonne Rozier and diagnosed by Gerard Holzmann.

* src/tgbaalgos/neverclaim.cc (process_link): Call
to_spin_string(..., true) to fully parentheses the string.
* src/tgbatest/neverclaimread.test: Add a test.
2011-11-16 14:27:50 +01:00
Alexandre Duret-Lutz
2422b63a36 Better documentation for print_tgba_run.
* src/tgbaalgos/emptiness.hh (print_tgba_run): Reword the
documentation after a report from Nikos Gorogiannis.
2011-10-26 19:05:55 +02:00
Alexandre Duret-Lutz
a4d1e18bf3 Safra: Fix usage of multiple acceptance conditions and fix text output.
* src/tgba/tgbasafracomplement.cc
(tgba_safra_complement::tgba_safra_complement)
(tgba_safra_complement::succ_iter): Correct the declaration and
use of multiple acceptance conditions.
(state_complement::to_string): Output the L set, not U.  The previous
code caused different states to share the same names, causing issues
with the text-based output (state with identical names get merged).
* src/tgba/tgbasafracomplement.hh
(tgba_safra_complement::acceptance_cond_vec_): Adjust type to
store BDDs.
* src/tgbatest/complementation.cc: Implement a new "-b" option
to output automata in Spot's syntax.
* src/tgbatest/complementation.test: Add a test-case supplied
by Martin Dieguez Lodeiro.
* THANKS: Add Martin.
2011-10-23 23:06:59 +02:00