-
Notifications
You must be signed in to change notification settings - Fork 5.4k
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
Implement Iteration for Bytes #6953
base: master
Are you sure you want to change the base?
Conversation
/// } | ||
/// } | ||
/// | ||
/// # Undefined Behavior |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/// # Undefined Behavior | |
/// # Undefined Behavior |
This should be addressed, maybe with a clone
sway-lib-std/src/bytes.sw
Outdated
// `Iterator` for other types. | ||
// | ||
// Due to the Sway's copy semantics, the `values` will | ||
// actually contain **a copy of the original vector |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sentences shouldn't start on a newline so forc doc can handle it correctly
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are internal comments not docs. I took these from the vector implementation
Description
Adds an iterator to allow for loops over bytes
Checklist
Breaking*
orNew Feature
labels where relevant.