Commit 22a3d1c3 authored by Alexandre Duret-Lutz's avatar Alexandre Duret-Lutz

remove options -! and -" from genltl

Fixes #237.

* bin/genltl.cc: Fix the numbering of options.
* NEWS: Mention the bugs.
parent 18283d69
......@@ -16,6 +16,9 @@ New in spot 2.3.1.dev (not yet released)
- Because of a typo, the output of --stats='...%P...' was correct
only if %p was used as well.
- genltl was never meant to have (randomly attributed) short
options for --postive and --negative.
Deprecation notices:
- Using --format=%a to print the number of atomic propositions in
......
......@@ -167,7 +167,8 @@ const char argp_program_doc[] ="\
Generate temporal logic formulas from predefined patterns.";
enum {
OPT_AND_F = 1,
FIRST_CLASS = 256,
OPT_AND_F = FIRST_CLASS,
OPT_AND_FG,
OPT_AND_GF,
OPT_CCJ_ALPHA,
......@@ -203,7 +204,7 @@ enum {
OPT_NEGATIVE,
};
const char* const class_name[LAST_CLASS] =
const char* const class_name[LAST_CLASS - FIRST_CLASS] =
{
"and-f",
"and-fg",
......@@ -1445,12 +1446,12 @@ output_pattern(int pattern, int n)
if (opt_positive || !opt_negative)
{
output_formula_checked(f, class_name[pattern - 1], n);
output_formula_checked(f, class_name[pattern - FIRST_CLASS], n);
}
if (opt_negative)
{
std::string tmp = "!";
tmp += class_name[pattern - 1];
tmp += class_name[pattern - FIRST_CLASS];
output_formula_checked(spot::formula::Not(f), tmp.c_str(), n);
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment