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

Remove unsafe from impl Compact for ClientVersion #11307

Closed
wants to merge 7 commits into from

Conversation

0xriazaka
Copy link
Contributor

unable to implement Compact for String directly (E0117 orphan rule), so CompactString wrapper used instead to safely manage byte-to-String conversion without unsafe code!

@mattsse mattsse added the A-db Related to the database label Sep 28, 2024
}
}

impl Compact for CompactString {
Copy link
Collaborator

Choose a reason for hiding this comment

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

you can move this to the reth-codecs crate, where the trait is defined, then you don't need the wrapper

@0xriazaka 0xriazaka closed this Sep 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-db Related to the database
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants