scc_info: introduce scc_and_mark_filter

* spot/twaalgos/sccinfo.hh, spot/twaalgos/sccinfo.cc: Here.
* spot/twaalgos/genem.cc: Use it.
* python/spot/impl.i, python/spot/__init__.py: Add bindings.
* tests/python/genem.py: Test it.
* NEWS: Mention it.
This commit is contained in:
Alexandre Duret-Lutz 2019-03-30 11:03:03 +01:00
parent 0d9c81a6d9
commit 55db24e00e
7 changed files with 256 additions and 48 deletions

View file

@ -75,6 +75,12 @@ namespace spot
};
}
scc_info::scc_info(scc_and_mark_filter& filt, scc_info_options options)
: scc_info(filt.get_aut(), filt.start_state(),
filt.get_filter(), &filt, options)
{
}
scc_info::scc_info(const_twa_graph_ptr aut,
unsigned initial_state,
edge_filter filter,
@ -716,6 +722,19 @@ namespace spot
unsigned dst)
{
cur[src] = seen[src] = true;
// if (filter_)
// {
// twa_graph::edge_storage_t e;
// e.cond = cond;
// e.src = src;
// e.dst = dst;
// if (filter_(e, dst, filter_data_)
// != edge_filter_choice::keep)
// {
// cond = bddfalse;
// return;
// }
// }
if (scc_of(dst) != scc
|| (m & sets)
|| (seen[dst] && !cur[dst]))