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

feat(cordyceps): add List::{front, back, front_mut, back_mut} #211

Merged
merged 1 commit into from
Jun 9, 2022

Conversation

hawkw
Copy link
Owner

@hawkw hawkw commented Jun 9, 2022

This branch adds accessors for the front and back elements of a
cordyceps::List. The returned elements are Pinned to prevent them
from being moved out of the list. The Pinning was not strictly
necessary for the immutable accessors but I did it for consistency with
the mutable ones...we could safely just have those return &T,
though.

This branch adds accessors for the front and back elements of a
`cordyceps::List`. The returned elements are `Pin`ned to prevent them
from being moved out of the list. The `Pin`ning was not strictly
necessary for the immutable accessors but I did it for consistency with
the mutable ones...we _could_ safely just have those return `&T`,
though.
@hawkw hawkw requested a review from jamesmunns June 9, 2022 16:00
Copy link
Collaborator

@jamesmunns jamesmunns left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall LGTM, up to you if you want to add (regular/miri/loom) tests here.

@hawkw hawkw merged commit f120827 into main Jun 9, 2022
@hawkw hawkw deleted the eliza/linked-list-accessors branch June 9, 2022 18:12
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 this pull request may close these issues.

None yet

2 participants