fix unabbreviate
This is a bug:
% ltlfilt -f 'a W b' --unabbreviate=WR
a U (b | (a W b))
* src/tl/unabbrev.cc: Here.
* src/tests/unabbrevwm.test: Harden test case.
* wrap/python/tests/randltl.ipynb: Adjust expected output.
* NEWS: Mention the fix.
This commit is contained in:
parent
43a5187ab4
commit
e1ddf97862
4 changed files with 14 additions and 10 deletions
|
|
@ -40,7 +40,10 @@ test `uniq out | wc -l` = 1
|
|||
for i in 'GFa' 'a R b' 'a W b' 'a M b'; do
|
||||
for fg in '' F G GF; do
|
||||
for rwm in '' R W M RW RM WM RWM; do
|
||||
$ltlfilt -f "$i" --unabbrev=$fg$rwm --equivalent-to "$i"
|
||||
$ltlfilt -f "$i" --unabbrev=$fg$rwm --equivalent-to "$i" >out
|
||||
test -n "$rwm" && grep "[$rwm]" out && exit 1
|
||||
done
|
||||
done
|
||||
done
|
||||
|
||||
true
|
||||
|
|
|
|||
|
|
@ -205,7 +205,7 @@ namespace spot
|
|||
auto gf2 = formula::G(f2);
|
||||
if (re_g_)
|
||||
gf2 = run(gf2);
|
||||
out = formula::U(f2, formula::Or({f12, out}));
|
||||
out = formula::U(f2, formula::Or({f12, gf2}));
|
||||
break;
|
||||
}
|
||||
case op::W:
|
||||
|
|
@ -225,8 +225,8 @@ namespace spot
|
|||
}
|
||||
auto gf1 = formula::G(f1);
|
||||
if (re_g_)
|
||||
gf1 = rec(gf1);
|
||||
out = formula::U(f1, formula::Or({f2, out}));
|
||||
gf1 = run(gf1);
|
||||
out = formula::U(f1, formula::Or({f2, gf1}));
|
||||
break;
|
||||
}
|
||||
case op::M:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue