tgbadigraph: delegate useful graph methods
* src/tgba/tgbagraph.hh (new_state, new_states, new_transitions, out, trans_data): Delegate these useful graph methods so we do not have to call get_graph(). * src/graphtest/tgbagraph.cc, src/tgbaalgos/dtbasat.cc, src/tgbaalgos/dtgbasat.cc, src/tgbaalgos/dupexp.cc, src/tgbaalgos/emptiness.cc, src/tgbaalgos/lbtt.cc, src/tgbaalgos/powerset.cc, src/tgbaalgos/randomgraph.cc, src/tgbaalgos/sccfilter.cc, src/tgbaalgos/sccinfo.cc,src/tgbaalgos/simulation.cc: Simplify.
This commit is contained in:
parent
18f6fe772b
commit
1a93166d15
12 changed files with 92 additions and 75 deletions
|
|
@ -287,7 +287,6 @@ namespace spot
|
|||
{
|
||||
auto d = a->get_dict();
|
||||
auto res = new tgba_digraph(d);
|
||||
auto& g = res->get_graph();
|
||||
d->register_all_variables_of(a, res);
|
||||
|
||||
const state* s = a->get_init_state();
|
||||
|
|
@ -308,7 +307,7 @@ namespace spot
|
|||
tgba_run::steps::const_iterator i = l->begin();
|
||||
|
||||
assert(s->compare(i->s) == 0);
|
||||
src = g.new_state();
|
||||
src = res->new_state();
|
||||
seen.insert(std::make_pair(i->s, src));
|
||||
|
||||
for (; i != l->end();)
|
||||
|
|
@ -358,10 +357,10 @@ namespace spot
|
|||
|
||||
auto p = seen.insert(std::make_pair(next, 0));
|
||||
if (p.second)
|
||||
p.first->second = g.new_state();
|
||||
p.first->second = res->new_state();
|
||||
dst = p.first->second;
|
||||
|
||||
g.new_transition(src, dst, label, acc);
|
||||
res->new_transition(src, dst, label, acc);
|
||||
src = dst;
|
||||
|
||||
// Sum acceptance conditions.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue