Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

allow getting node using usize as an index. #101

Closed
coderedart opened this issue Feb 17, 2024 · 0 comments · Fixed by #102
Closed

allow getting node using usize as an index. #101

coderedart opened this issue Feb 17, 2024 · 0 comments · Fixed by #102

Comments

@coderedart
Copy link
Contributor

I need to pass around the NodeID via ffi functions. And because its an opaque rust struct, I decided to simply get the usize and use that as the node_id for the sake of simplicity.

But, NodeID also has a version, making it impossible to get the original NodeID from just the usize.

It would be nice if the arena had a function to get the current NodeID at the index usize (or None if it doesn't exist).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant