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

Add from_u8_masked RecoveryId constructor #778

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

jamillambert
Copy link
Contributor

Add an infallible constructor that takes a u8 and masks off the top 6 bits.

Mentioned in rust-bitcoin/rust-bitcoin#3965

Add an infallible constructor that takes a u8 and masks off the top 6
bits.
@jamillambert
Copy link
Contributor Author

I was not 100% sure how to handle the 3, if it should be a case and then have an _ that cannot be reached? or as it is.

Copy link
Member

@tcharding tcharding left a comment

Choose a reason for hiding this comment

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

ACK 252053c

@tcharding
Copy link
Member

I was not 100% sure how to handle the 3

It's good like it is IMO.

@tcharding
Copy link
Member

FYI the CI failure is unrelated.

@jamillambert
Copy link
Contributor Author

FYI the CI failure is unrelated.

Thanks, I did look into it and couldn't see any reason for this PR causing it.

Copy link
Collaborator

@Kixunil Kixunil left a comment

Choose a reason for hiding this comment

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

ACK 252053c

Copy link
Member

@apoelstra apoelstra left a comment

Choose a reason for hiding this comment

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

ACK 252053c; successfully ran local tests

@apoelstra apoelstra merged commit e66bd11 into rust-bitcoin:master Jan 28, 2025
29 of 30 checks passed
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.

4 participants