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

[derive] Implement an IntoBytes-based PartialEq/Eq derive #2285

Merged
merged 2 commits into from
Feb 3, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/lib.rs
Copy link
Collaborator

Choose a reason for hiding this comment

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

I'm surprised that rustfmt didn't catch this — something to dig into, I think.

Original file line number Diff line number Diff line change
Expand Up @@ -5460,9 +5460,9 @@ pub use zerocopy_derive::ByteHash;
/// that implement [`IntoBytes`] and [`Immutable`].
///
/// The standard library's derive for [`PartialEq`] generates a recursive
///descent into the fields of the type it is applied to. Instead, the
///implementation derived by this macro performs a single slice comparison of
///the bytes of the two values being compared.
/// descent into the fields of the type it is applied to. Instead, the
/// implementation derived by this macro performs a single slice comparison of
/// the bytes of the two values being compared.
#[cfg(any(feature = "derive", test))]
#[cfg_attr(doc_cfg, doc(cfg(feature = "derive")))]
pub use zerocopy_derive::ByteEq;
Expand Down
Loading