-
Notifications
You must be signed in to change notification settings - Fork 156
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: add Program
method for iterating identifiers
#1079
Conversation
Benchmark Results for unmodified programs 🚀
|
Codecov Report
@@ Coverage Diff @@
## main #1079 +/- ##
=======================================
Coverage 98.09% 98.09%
=======================================
Files 84 84
Lines 33867 33935 +68
=======================================
+ Hits 33222 33290 +68
Misses 645 645
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
CHANGELOG.md
Outdated
@@ -115,6 +115,8 @@ Add missing hint on vrf.json lib [#1053](https://github.com/lambdaclass/cairo-rs | |||
segments.write_arg(ids.blake2s_ptr_end, padding) | |||
%} | |||
|
|||
* Add `Program::iter_identifiers(&self) -> Iterator<Item = (&String, &Identifier)>` to get an iterator over the program's identifiers [#1079](https://github.com/lambdaclass/cairo-rs/pull/1079) |
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.
Make this Program::iter_identifiers(&self) -> Iterator<Item = (&str, &Identifier)>
.
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.
Done!
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.
LGTM
* Add `Program::iter_identifiers` * Add unit test * Update changelog * Change &String -> &str
Description
This PR adds
Program::iter_identifiers
, to let crate consumers access all of a program's identifiers without accessing it's attributes.Checklist