Move lexicographical_topological_sort()
functionality to rustworkx-core
#1165
Labels
rustworkx-core
Issues tracking adding functionality to rustworkx-core
The
lexicographical_topological_sort()
function is only exposed via a Python interface currently:rustworkx/src/dag_algo/mod.rs
Lines 347 to 485 in ab93329
We should port it to rustworkx-core, so that rust users can leverage the function.
One tweak that probably makes sense for the rustworkx-core version is that instead of returning a
PyList
(realistically aVec<N>
) of node weights we should have it return of an iterator of node ids. This would be more flexible and performant for rust space users and for the python side of rustworkx we can just consume the iterator to build the pylist return there (for api compatibility).The text was updated successfully, but these errors were encountered: