tgbagraph: add a merge_transitions() method.
* src/graph/graph.hh: Add some framework to erase transitions, and defrag the resulting transitions_ vector on demand. Also remove the nb_states() and nb_transitions() because num_states() and num_transitions() already exist. * src/graphtest/graph.cc, src/graphtest/ngraph.cc: Adjust to use num_states(). * src/tgba/tgbagraph.hh (merge_transitions): New method. * src/misc/hash.hh: Add a pair_hash class, needed by merge_transitions(). * src/graphtest/tgbagraph.cc, src/graphtest/tgbagraph.test: Add states for transitions removal and merge_transitions().
This commit is contained in:
parent
9909699c63
commit
424de90385
7 changed files with 286 additions and 10 deletions
|
|
@ -55,7 +55,7 @@ void
|
|||
dot(std::ostream& out, spot::digraph<SL, TL>& g)
|
||||
{
|
||||
out << "digraph {\n";
|
||||
unsigned c = g.nb_states();
|
||||
unsigned c = g.num_states();
|
||||
for (unsigned s = 0; s < c; ++s)
|
||||
{
|
||||
out << ' ' << s;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue