Skip to content

feat: SmtLeaf::try_from_elements()#773

Merged
bobbinth merged 3 commits intonextfrom
sergerad-smt-leaf-try-from-elements
Jan 14, 2026
Merged

feat: SmtLeaf::try_from_elements()#773
bobbinth merged 3 commits intonextfrom
sergerad-smt-leaf-try-from-elements

Conversation

@sergerad
Copy link
Copy Markdown
Contributor

Adds a conversion function for a list of Felts to SmtLeaf.

Closes #772.

Copy link
Copy Markdown
Contributor

@bobbinth bobbinth left a comment

Choose a reason for hiding this comment

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

Looks great! Thank you! I left just a few small comments inline.

Copy link
Copy Markdown
Contributor

@PhilippGackstatter PhilippGackstatter left a comment

Choose a reason for hiding this comment

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

Looks good to me.

I think the tests can be simplified, but not critical.

@bobbinth bobbinth changed the base branch from next to main January 14, 2026 18:26
@huitseeker huitseeker force-pushed the sergerad-smt-leaf-try-from-elements branch from 531ad05 to f621e3f Compare January 14, 2026 19:43
@huitseeker huitseeker changed the base branch from main to next January 14, 2026 19:43
sergerad and others added 3 commits January 14, 2026 14:44
- Rename ConversionError to DecodingError for clearer semantics
- Add DOUBLE_WORD_LEN constant to replace magic number 8
- Refactor to_elements() to return an iterator instead of Vec
- Simplify tests using round-trip pattern per PhilippGackstatter's suggestion
@huitseeker huitseeker force-pushed the sergerad-smt-leaf-try-from-elements branch from f621e3f to 6c635c5 Compare January 14, 2026 19:45
Copy link
Copy Markdown
Contributor

@bobbinth bobbinth left a comment

Choose a reason for hiding this comment

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

All looks good! Thank you!

@bobbinth bobbinth merged commit 336c985 into next Jan 14, 2026
27 checks passed
@bobbinth bobbinth deleted the sergerad-smt-leaf-try-from-elements branch January 14, 2026 20:01
sergerad added a commit that referenced this pull request Feb 24, 2026
sergerad added a commit that referenced this pull request Feb 24, 2026
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.

Implement SmtLeaf::try_from_elements

4 participants