fix previous patch

this patch failed on i386 and on Raspberry.

* spot/twaalgos/translate.cc: Clear.
* spot/twaalgos/postproc.cc: Call reduce_parity_here
in more cases.
This commit is contained in:
Alexandre Duret-Lutz 2022-10-05 16:29:47 +02:00
parent 344e01d4e2
commit 05b8fa8dbf
2 changed files with 7 additions and 4 deletions

View file

@ -239,11 +239,13 @@ namespace spot
{
if (PREF_ != Any && level_ != Low)
tmp->remove_unused_ap();
if (COMP_)
bool was_complete = tmp->prop_complete().is_true();
if (COMP_ && !was_complete)
tmp = complete(tmp);
bool want_parity = type_ & Parity;
if (want_parity && (tmp->acc().is_generalized_buchi()
|| tmp->acc().is_generalized_co_buchi()))
if (want_parity && tmp->num_sets() > 1
&& (tmp->acc().is_generalized_buchi()
|| tmp->acc().is_generalized_co_buchi()))
tmp = choose_degen(tmp);
assert(!!SBACC_ == state_based_);
if (state_based_)
@ -252,7 +254,7 @@ namespace spot
tmp = ensure_ba(tmp);
if (want_parity)
{
if (!acd_was_used_)
if (!acd_was_used_ || (COMP_ && !was_complete))
reduce_parity_here(tmp, COLORED_);
parity_kind kind = parity_kind_any;
parity_style style = parity_style_any;

View file

@ -387,6 +387,7 @@ namespace spot
|| type_ == GeneralizedBuchi)
aut2 = gf_guarantee_to_ba_maybe(r, simpl_->get_dict(),
det, state_based_);
acd_was_used_ = false;
if (aut2 && (pref_ & Deterministic))
return finalize(aut2);
if (!aut2 && (type_ == Generic