acc: simplify interface using operators

* spot/twa/acc.hh, spot/twa/acc.cc: Here.  Also remove
some redundant functions.
* spot/parseaut/parseaut.yy, spot/priv/accmap.hh, spot/tests/acc.cc,
spot/tests/twagraph.cc, spot/twa/taatgba.hh, spot/twa/twaproduct.cc,
spot/twaalgos/dtwasat.cc, spot/twaalgos/hoa.cc, spot/twaalgos/lbtt.cc,
spot/twaalgos/ltl2tgba_fm.cc, spot/twaalgos/product.cc,
spot/twaalgos/remfin.cc, spot/twaalgos/simulation.cc,
spot/twaalgos/tau03opt.cc, spot/twaalgos/weight.cc,
spot/twaalgos/weight.hh: Adjust.
* NEWS: Mention the changes.
This commit is contained in:
Alexandre Duret-Lutz 2015-12-16 18:49:11 +01:00
parent c39d35d068
commit 4993e80706
19 changed files with 161 additions and 154 deletions

View file

@ -64,7 +64,7 @@ namespace spot
auto p = map_.find(name);
if (p == map_.end())
return std::make_pair(false, 0U);
return std::make_pair(true, aut_->acc().marks({p->second}));
return std::make_pair(true, acc_cond::mark_t({p->second}));
}
};
@ -83,7 +83,7 @@ namespace spot
std::pair<bool, acc_cond::mark_t> lookup(unsigned n)
{
if (n < aut_->acc().num_sets())
return std::make_pair(true, aut_->acc().marks({n}));
return std::make_pair(true, acc_cond::mark_t({n}));
else
return std::make_pair(false, 0U);
}
@ -109,7 +109,7 @@ namespace spot
return std::make_pair(true, p->second);
if (used_ < aut_->acc().num_sets())
{
auto res = aut_->acc().marks({used_++});
auto res = acc_cond::mark_t({used_++});
map_[n] = res;
return std::make_pair(true, res);
}