forked from Qiskit/rustworkx
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move bfs_successors and bfs_predecessors to rustworkx-core (Qiskit#1209)
This commit adds an implementation of the bfs_successors and bfs_predecessors functions to the rustworkx-core crate exposing the functions to rust users. The existing implementation in the rustworkx crate is removed and it is updated to call the rustworkx-core functions. The rustwork-core functions return an iterator of nodes indices and the Python crate side consumes the iterator to build the bfs view these functions previously returned.
- Loading branch information
Showing
3 changed files
with
215 additions
and
33 deletions.
There are no files selected for viewing
12 changes: 12 additions & 0 deletions
12
releasenotes/notes/bfs-pred-succ-rustworkx-core-480d25a374294899.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
--- | ||
features: | ||
- | | ||
Added a new function ``bfs_predecessors()`` to the | ||
``rustworkx_core::traversal`` module. That is a generic Rust implementation | ||
for the core rust library that provides the | ||
:func:`.bfs_predecessors` function to Rust users. | ||
- | | ||
Added a new function ``bfs_successors()`` to the | ||
``rustworkx_core::traversal`` module. That is a generic Rust implementation | ||
for the core rust library that provides the | ||
:func:`.bfs_successors` function to Rust users. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters