Trait origin_studio::std::cmp::PartialEq
1.0.0 · source · pub trait PartialEq<Rhs = Self>where
Rhs: ?Sized,{
// Required method
fn eq(&self, other: &Rhs) -> bool;
// Provided method
fn ne(&self, other: &Rhs) -> bool { ... }
}Expand description
Trait for equality comparisons.
x.eq(y) can also be written x == y, and x.ne(y) can be written x != y.
We use the easier-to-read infix notation in the remainder of this documentation.
This trait allows for partial equality, for types that do not have a full
equivalence relation. For example, in floating point numbers NaN != NaN,
so floating point types implement PartialEq but not Eq.
Formally speaking, when Rhs == Self, this trait corresponds to a partial equivalence
relation.
Implementations must ensure that eq and ne are consistent with each other:
a != bif and only if!(a == b).
The default implementation of ne provides this consistency and is almost
always sufficient. It should not be overridden without very good reason.
If PartialOrd or Ord are also implemented for Self and Rhs, their methods must also
be consistent with PartialEq (see the documentation of those traits for the exact
requirements). It’s easy to accidentally make them disagree by deriving some of the traits and
manually implementing others.
The equality relation == must satisfy the following conditions
(for all a, b, c of type A, B, C):
-
Symmetric: if
A: PartialEq<B>andB: PartialEq<A>, thena == bimpliesb == a; and -
Transitive: if
A: PartialEq<B>andB: PartialEq<C>andA: PartialEq<C>, thena == bandb == cimpliesa == c.
Note that the B: PartialEq<A> (symmetric) and A: PartialEq<C>
(transitive) impls are not forced to exist, but these requirements apply
whenever they do exist.
Derivable
This trait can be used with #[derive]. When derived on structs, two
instances are equal if all fields are equal, and not equal if any fields
are not equal. When derived on enums, two instances are equal if they
are the same variant and all fields are equal.
How can I implement PartialEq?
An example implementation for a domain in which two books are considered the same book if their ISBN matches, even if the formats differ:
enum BookFormat {
Paperback,
Hardback,
Ebook,
}
struct Book {
isbn: i32,
format: BookFormat,
}
impl PartialEq for Book {
fn eq(&self, other: &Self) -> bool {
self.isbn == other.isbn
}
}
let b1 = Book { isbn: 3, format: BookFormat::Paperback };
let b2 = Book { isbn: 3, format: BookFormat::Ebook };
let b3 = Book { isbn: 10, format: BookFormat::Paperback };
assert!(b1 == b2);
assert!(b1 != b3);How can I compare two different types?
The type you can compare with is controlled by PartialEq’s type parameter.
For example, let’s tweak our previous code a bit:
// The derive implements <BookFormat> == <BookFormat> comparisons
#[derive(PartialEq)]
enum BookFormat {
Paperback,
Hardback,
Ebook,
}
struct Book {
isbn: i32,
format: BookFormat,
}
// Implement <Book> == <BookFormat> comparisons
impl PartialEq<BookFormat> for Book {
fn eq(&self, other: &BookFormat) -> bool {
self.format == *other
}
}
// Implement <BookFormat> == <Book> comparisons
impl PartialEq<Book> for BookFormat {
fn eq(&self, other: &Book) -> bool {
*self == other.format
}
}
let b1 = Book { isbn: 3, format: BookFormat::Paperback };
assert!(b1 == BookFormat::Paperback);
assert!(BookFormat::Ebook != b1);By changing impl PartialEq for Book to impl PartialEq<BookFormat> for Book,
we allow BookFormats to be compared with Books.
A comparison like the one above, which ignores some fields of the struct,
can be dangerous. It can easily lead to an unintended violation of the
requirements for a partial equivalence relation. For example, if we kept
the above implementation of PartialEq<Book> for BookFormat and added an
implementation of PartialEq<Book> for Book (either via a #[derive] or
via the manual implementation from the first example) then the result would
violate transitivity:
#[derive(PartialEq)]
enum BookFormat {
Paperback,
Hardback,
Ebook,
}
#[derive(PartialEq)]
struct Book {
isbn: i32,
format: BookFormat,
}
impl PartialEq<BookFormat> for Book {
fn eq(&self, other: &BookFormat) -> bool {
self.format == *other
}
}
impl PartialEq<Book> for BookFormat {
fn eq(&self, other: &Book) -> bool {
*self == other.format
}
}
fn main() {
let b1 = Book { isbn: 1, format: BookFormat::Paperback };
let b2 = Book { isbn: 2, format: BookFormat::Paperback };
assert!(b1 == BookFormat::Paperback);
assert!(BookFormat::Paperback == b2);
// The following should hold by transitivity but doesn't.
assert!(b1 == b2); // <-- PANICS
}Examples
let x: u32 = 0;
let y: u32 = 1;
assert_eq!(x == y, false);
assert_eq!(x.eq(&y), false);Required Methods§
Provided Methods§
Implementors§
impl PartialEq<AsciiChar> for AsciiChar
impl PartialEq<TryReserveErrorKind> for TryReserveErrorKind
impl PartialEq<Infallible> for Infallible
impl PartialEq<VarError> for VarError
impl PartialEq<Alignment> for origin_studio::std::fmt::Alignment
impl PartialEq<IpAddr> for IpAddr
impl PartialEq<IpAddr> for Ipv4Addr
impl PartialEq<IpAddr> for Ipv6Addr
impl PartialEq<Ipv6MulticastScope> for Ipv6MulticastScope
impl PartialEq<SocketAddr> for SocketAddr
impl PartialEq<FpCategory> for FpCategory
impl PartialEq<IntErrorKind> for IntErrorKind
impl PartialEq<Which> for Which
impl PartialEq<SearchStep> for SearchStep
impl PartialEq<Ordering> for origin_studio::std::sync::atomic::Ordering
impl PartialEq<Ordering> for origin_studio::std::cmp::Ordering
impl PartialEq<Advice> for rustix::backend::fs::types::Advice
impl PartialEq<FileType> for FileType
impl PartialEq<FlockOperation> for FlockOperation
impl PartialEq<Advice> for rustix::backend::mm::types::Advice
impl PartialEq<MembarrierCommand> for MembarrierCommand
impl PartialEq<Resource> for Resource
impl PartialEq<FutexOperation> for FutexOperation
impl PartialEq<TimerfdClockId> for TimerfdClockId
impl PartialEq<ClockId> for ClockId
impl PartialEq<SeekFrom> for SeekFrom
impl PartialEq<Direction> for Direction
impl PartialEq<DumpableBehavior> for DumpableBehavior
impl PartialEq<EndianMode> for EndianMode
impl PartialEq<FloatingPointMode> for FloatingPointMode
impl PartialEq<MachineCheckMemoryCorruptionKillPolicy> for MachineCheckMemoryCorruptionKillPolicy
impl PartialEq<PTracer> for PTracer
impl PartialEq<SpeculationFeature> for SpeculationFeature
impl PartialEq<TimeStampCounterReadability> for TimeStampCounterReadability
impl PartialEq<TimingMethod> for TimingMethod
impl PartialEq<VirtualMemoryMapAddress> for VirtualMemoryMapAddress
impl PartialEq<Signal> for Signal
impl PartialEq<Capability> for Capability
impl PartialEq<CoreSchedulingScope> for CoreSchedulingScope
impl PartialEq<SecureComputingMode> for SecureComputingMode
impl PartialEq<SysCallUserDispatchFastSwitch> for SysCallUserDispatchFastSwitch
impl PartialEq<LinkNameSpaceType> for LinkNameSpaceType
impl PartialEq<bool> for bool
impl PartialEq<char> for char
impl PartialEq<f32> for f32
impl PartialEq<f64> for f64
impl PartialEq<i8> for i8
impl PartialEq<i16> for i16
impl PartialEq<i32> for i32
impl PartialEq<i64> for i64
impl PartialEq<i128> for i128
impl PartialEq<isize> for isize
impl PartialEq<!> for !
impl PartialEq<str> for str
impl PartialEq<u8> for u8
impl PartialEq<u16> for u16
impl PartialEq<u32> for u32
impl PartialEq<u64> for u64
impl PartialEq<u128> for u128
impl PartialEq<()> for ()
impl PartialEq<usize> for usize
impl PartialEq<AllocError> for AllocError
impl PartialEq<Layout> for Layout
impl PartialEq<LayoutError> for LayoutError
impl PartialEq<TypeId> for TypeId
impl PartialEq<CpuidResult> for CpuidResult
impl PartialEq<CharTryFromError> for CharTryFromError
impl PartialEq<DecodeUtf16Error> for DecodeUtf16Error
impl PartialEq<ParseCharError> for ParseCharError
impl PartialEq<TryFromCharError> for TryFromCharError
impl PartialEq<TryReserveError> for TryReserveError
impl PartialEq<CString> for CString
impl PartialEq<FromVecWithNulError> for FromVecWithNulError
impl PartialEq<IntoStringError> for IntoStringError
impl PartialEq<NulError> for NulError
impl PartialEq<Error> for origin_studio::std::fmt::Error
impl PartialEq<PhantomPinned> for PhantomPinned
impl PartialEq<Assume> for Assume
impl PartialEq<AddrParseError> for AddrParseError
impl PartialEq<Ipv4Addr> for IpAddr
impl PartialEq<Ipv4Addr> for Ipv4Addr
impl PartialEq<Ipv6Addr> for IpAddr
impl PartialEq<Ipv6Addr> for Ipv6Addr
impl PartialEq<SocketAddrV4> for SocketAddrV4
impl PartialEq<SocketAddrV6> for SocketAddrV6
impl PartialEq<NonZeroI8> for NonZeroI8
impl PartialEq<NonZeroI16> for NonZeroI16
impl PartialEq<NonZeroI32> for NonZeroI32
impl PartialEq<NonZeroI64> for NonZeroI64
impl PartialEq<NonZeroI128> for NonZeroI128
impl PartialEq<NonZeroIsize> for NonZeroIsize
impl PartialEq<NonZeroU8> for NonZeroU8
impl PartialEq<NonZeroU16> for NonZeroU16
impl PartialEq<NonZeroU32> for NonZeroU32
impl PartialEq<NonZeroU64> for NonZeroU64
impl PartialEq<NonZeroU128> for NonZeroU128
impl PartialEq<NonZeroUsize> for NonZeroUsize
impl PartialEq<ParseFloatError> for ParseFloatError
impl PartialEq<ParseIntError> for ParseIntError
impl PartialEq<TryFromIntError> for TryFromIntError
impl PartialEq<RangeFull> for RangeFull
impl PartialEq<Alignment> for origin_studio::std::ptr::Alignment
impl PartialEq<ParseBoolError> for ParseBoolError
impl PartialEq<Utf8Error> for Utf8Error
impl PartialEq<FromUtf8Error> for FromUtf8Error
impl PartialEq<String> for String
impl PartialEq<Duration> for Duration
impl PartialEq<TryFromFloatSecsError> for TryFromFloatSecsError
impl PartialEq<CStr> for CStr
impl PartialEq<FromBytesUntilNulError> for FromBytesUntilNulError
impl PartialEq<FromBytesWithNulError> for FromBytesWithNulError
impl PartialEq<RawWaker> for RawWaker
impl PartialEq<RawWakerVTable> for RawWakerVTable
impl PartialEq<CreateFlags> for CreateFlags
impl PartialEq<WatchFlags> for WatchFlags
impl PartialEq<Access> for Access
impl PartialEq<AtFlags> for AtFlags
impl PartialEq<FallocateFlags> for FallocateFlags
impl PartialEq<MemfdFlags> for MemfdFlags
impl PartialEq<Mode> for Mode
impl PartialEq<OFlags> for OFlags
impl PartialEq<RenameFlags> for RenameFlags
impl PartialEq<ResolveFlags> for ResolveFlags
impl PartialEq<SealFlags> for SealFlags
impl PartialEq<StatVfsMountFlags> for StatVfsMountFlags
impl PartialEq<StatxFlags> for StatxFlags
impl PartialEq<Errno> for Errno
impl PartialEq<DupFlags> for DupFlags
impl PartialEq<FdFlags> for FdFlags
impl PartialEq<ReadWriteFlags> for ReadWriteFlags
impl PartialEq<MapFlags> for MapFlags
impl PartialEq<MlockFlags> for MlockFlags
impl PartialEq<MprotectFlags> for MprotectFlags
impl PartialEq<MremapFlags> for MremapFlags
impl PartialEq<MsyncFlags> for MsyncFlags
impl PartialEq<ProtFlags> for ProtFlags
impl PartialEq<UserfaultfdFlags> for UserfaultfdFlags
impl PartialEq<MountFlags> for MountFlags
impl PartialEq<MountPropagationFlags> for MountPropagationFlags
impl PartialEq<UnmountFlags> for UnmountFlags
impl PartialEq<PipeFlags> for PipeFlags
impl PartialEq<SpliceFlags> for SpliceFlags
impl PartialEq<FutexFlags> for FutexFlags
impl PartialEq<TimerfdFlags> for TimerfdFlags
impl PartialEq<TimerfdTimerFlags> for TimerfdTimerFlags
impl PartialEq<XattrFlags> for XattrFlags
impl PartialEq<Opcode> for Opcode
impl PartialEq<Pid> for Pid
impl PartialEq<Cpuid> for Cpuid
impl PartialEq<MembarrierQuery> for MembarrierQuery
impl PartialEq<PidfdFlags> for PidfdFlags
impl PartialEq<PidfdGetfdFlags> for PidfdGetfdFlags
impl PartialEq<FloatingPointEmulationControl> for FloatingPointEmulationControl
impl PartialEq<FloatingPointExceptionMode> for FloatingPointExceptionMode
impl PartialEq<SpeculationFeatureControl> for SpeculationFeatureControl
impl PartialEq<SpeculationFeatureState> for SpeculationFeatureState
impl PartialEq<UnalignedAccessControl> for UnalignedAccessControl
impl PartialEq<Rlimit> for Rlimit
impl PartialEq<CpuSet> for CpuSet
impl PartialEq<WaitOptions> for WaitOptions
impl PartialEq<WaitidOptions> for WaitidOptions
impl PartialEq<CapabilityFlags> for CapabilityFlags
impl PartialEq<CapabilitySets> for CapabilitySets
impl PartialEq<CapabilitiesSecureBits> for CapabilitiesSecureBits
impl PartialEq<SVEVectorLengthConfig> for SVEVectorLengthConfig
impl PartialEq<TaggedAddressMode> for TaggedAddressMode
impl PartialEq<ThreadNameSpaceType> for ThreadNameSpaceType
impl PartialEq<Gid> for Gid
impl PartialEq<Uid> for Uid
impl PartialEq<ArangeEntry> for ArangeEntry
impl PartialEq<Augmentation> for Augmentation
impl PartialEq<BaseAddresses> for BaseAddresses
impl PartialEq<BigEndian> for BigEndian
impl PartialEq<DebugTypeSignature> for DebugTypeSignature
impl PartialEq<DwAccess> for DwAccess
impl PartialEq<DwAddr> for DwAddr
impl PartialEq<DwAt> for DwAt
impl PartialEq<DwAte> for DwAte
impl PartialEq<DwCc> for DwCc
impl PartialEq<DwCfa> for DwCfa
impl PartialEq<DwChildren> for DwChildren
impl PartialEq<DwDefaulted> for DwDefaulted
impl PartialEq<DwDs> for DwDs
impl PartialEq<DwDsc> for DwDsc
impl PartialEq<DwEhPe> for DwEhPe
impl PartialEq<DwEnd> for DwEnd
impl PartialEq<DwForm> for DwForm
impl PartialEq<DwId> for DwId
impl PartialEq<DwIdx> for DwIdx
impl PartialEq<DwInl> for DwInl
impl PartialEq<DwLang> for DwLang
impl PartialEq<DwLle> for DwLle
impl PartialEq<DwLnct> for DwLnct
impl PartialEq<DwLne> for DwLne
impl PartialEq<DwLns> for DwLns
impl PartialEq<DwMacro> for DwMacro
impl PartialEq<DwOp> for DwOp
impl PartialEq<DwOrd> for DwOrd
impl PartialEq<DwRle> for DwRle
impl PartialEq<DwSect> for DwSect
impl PartialEq<DwSectV2> for DwSectV2
impl PartialEq<DwTag> for DwTag
impl PartialEq<DwUt> for DwUt
impl PartialEq<DwVirtuality> for DwVirtuality
impl PartialEq<DwVis> for DwVis
impl PartialEq<DwarfFileType> for DwarfFileType
impl PartialEq<DwoId> for DwoId
impl PartialEq<Encoding> for Encoding
impl PartialEq<Error> for Error
impl PartialEq<Format> for Format
impl PartialEq<LineEncoding> for LineEncoding
impl PartialEq<LittleEndian> for LittleEndian
impl PartialEq<Pointer> for Pointer
impl PartialEq<Range> for Range
impl PartialEq<ReaderOffsetId> for ReaderOffsetId
impl PartialEq<Register> for Register
impl PartialEq<RunTimeEndian> for RunTimeEndian
impl PartialEq<SectionBaseAddresses> for SectionBaseAddresses
impl PartialEq<SectionId> for SectionId
impl PartialEq<StoreOnHeap> for StoreOnHeap
impl PartialEq<UnitIndexSection> for UnitIndexSection
impl PartialEq<UnwindAction> for UnwindAction
impl PartialEq<UnwindReasonCode> for UnwindReasonCode
impl PartialEq<Value> for Value
impl PartialEq<ValueType> for ValueType
impl PartialEq<__kernel_timespec> for __kernel_timespec
impl PartialEq<fsconfig_command> for fsconfig_command
impl PartialEq<membarrier_cmd> for membarrier_cmd
impl PartialEq<membarrier_cmd_flag> for membarrier_cmd_flag
impl<'a> PartialEq<Location<'a>> for origin_studio::std::panic::Location<'a>
impl<'a> PartialEq<Utf8Chunk<'a>> for Utf8Chunk<'a>
impl<'a, 'b> PartialEq<&'a str> for String
impl<'a, 'b> PartialEq<&'b str> for Cow<'a, str>
impl<'a, 'b> PartialEq<Cow<'a, str>> for &'b str
impl<'a, 'b> PartialEq<Cow<'a, str>> for str
impl<'a, 'b> PartialEq<Cow<'a, str>> for String
impl<'a, 'b> PartialEq<str> for Cow<'a, str>
impl<'a, 'b> PartialEq<str> for String
impl<'a, 'b> PartialEq<String> for &'a str
impl<'a, 'b> PartialEq<String> for Cow<'a, str>
impl<'a, 'b> PartialEq<String> for str
impl<'a, 'b, B, C> PartialEq<Cow<'b, C>> for Cow<'a, B>where B: PartialEq<C> + ToOwned + ?Sized, C: ToOwned + ?Sized,
impl<'bases, Section, R> PartialEq<CieOrFde<'bases, Section, R>> for CieOrFde<'bases, Section, R>where Section: PartialEq<Section> + UnwindSection<R>, R: PartialEq<R> + Reader,
impl<'bases, Section, R> PartialEq<PartialFrameDescriptionEntry<'bases, Section, R>> for PartialFrameDescriptionEntry<'bases, Section, R>where Section: PartialEq<Section> + UnwindSection<R>, R: PartialEq<R> + Reader, <R as Reader>::Offset: PartialEq<<R as Reader>::Offset>, <Section as UnwindSection<R>>::Offset: PartialEq<<Section as UnwindSection<R>>::Offset>,
impl<'input, Endian> PartialEq<EndianSlice<'input, Endian>> for EndianSlice<'input, Endian>where Endian: PartialEq<Endian> + Endianity,
impl<A, B> PartialEq<&B> for &Awhere A: PartialEq<B> + ?Sized, B: ?Sized,
impl<A, B> PartialEq<&B> for &mut Awhere A: PartialEq<B> + ?Sized, B: ?Sized,
impl<A, B> PartialEq<&mut B> for &Awhere A: PartialEq<B> + ?Sized, B: ?Sized,
impl<A, B> PartialEq<&mut B> for &mut Awhere A: PartialEq<B> + ?Sized, B: ?Sized,
impl<A, B> PartialEq<[B]> for [A]where A: PartialEq<B>,
impl<A, B, const N: usize> PartialEq<&[B]> for [A; N]where A: PartialEq<B>,
impl<A, B, const N: usize> PartialEq<&mut [B]> for [A; N]where A: PartialEq<B>,
impl<A, B, const N: usize> PartialEq<[A; N]> for &[B]where B: PartialEq<A>,
impl<A, B, const N: usize> PartialEq<[A; N]> for &mut [B]where B: PartialEq<A>,
impl<A, B, const N: usize> PartialEq<[A; N]> for [B]where B: PartialEq<A>,
impl<A, B, const N: usize> PartialEq<[B; N]> for [A; N]where A: PartialEq<B>,
impl<A, B, const N: usize> PartialEq<[B]> for [A; N]where A: PartialEq<B>,
impl<B, C> PartialEq<ControlFlow<B, C>> for ControlFlow<B, C>where B: PartialEq<B>, C: PartialEq<C>,
impl<Dyn> PartialEq<DynMetadata<Dyn>> for DynMetadata<Dyn>where Dyn: ?Sized,
impl<F> PartialEq<F> for Fwhere F: FnPtr,
impl<H> PartialEq<BuildHasherDefault<H>> for BuildHasherDefault<H>
impl<Idx> PartialEq<Range<Idx>> for origin_studio::std::ops::Range<Idx>where Idx: PartialEq<Idx>,
impl<Idx> PartialEq<RangeFrom<Idx>> for RangeFrom<Idx>where Idx: PartialEq<Idx>,
impl<Idx> PartialEq<RangeInclusive<Idx>> for RangeInclusive<Idx>where Idx: PartialEq<Idx>,
impl<Idx> PartialEq<RangeTo<Idx>> for RangeTo<Idx>where Idx: PartialEq<Idx>,
impl<Idx> PartialEq<RangeToInclusive<Idx>> for RangeToInclusive<Idx>where Idx: PartialEq<Idx>,
impl<K, V, A> PartialEq<BTreeMap<K, V, A>> for BTreeMap<K, V, A>where K: PartialEq<K>, V: PartialEq<V>, A: Allocator + Clone,
impl<P, Q> PartialEq<Pin<Q>> for Pin<P>where P: Deref, Q: Deref, <P as Deref>::Target: PartialEq<<Q as Deref>::Target>,
impl<R> PartialEq<CallFrameInstruction<R>> for CallFrameInstruction<R>where R: PartialEq<R> + Reader,
impl<R> PartialEq<CfaRule<R>> for CfaRule<R>where R: PartialEq<R> + Reader,
impl<R> PartialEq<DebugFrame<R>> for DebugFrame<R>where R: PartialEq<R> + Reader,
impl<R> PartialEq<EhFrame<R>> for EhFrame<R>where R: PartialEq<R> + Reader,
impl<R> PartialEq<EhFrameHdr<R>> for EhFrameHdr<R>where R: PartialEq<R> + Reader,
impl<R> PartialEq<EvaluationResult<R>> for EvaluationResult<R>where R: PartialEq<R> + Reader, <R as Reader>::Offset: PartialEq<<R as Reader>::Offset>,
impl<R> PartialEq<Expression<R>> for Expression<R>where R: PartialEq<R> + Reader,
impl<R> PartialEq<LocationListEntry<R>> for LocationListEntry<R>where R: PartialEq<R> + Reader,
impl<R> PartialEq<RegisterRule<R>> for RegisterRule<R>where R: PartialEq<R> + Reader,
impl<R, A> PartialEq<UnwindContext<R, A>> for UnwindContext<R, A>where R: PartialEq<R> + Reader, A: PartialEq<A> + UnwindContextStorage<R>, <A as UnwindContextStorage<R>>::Stack: PartialEq<<A as UnwindContextStorage<R>>::Stack>,
impl<R, Offset> PartialEq<ArangeHeader<R, Offset>> for ArangeHeader<R, Offset>where R: PartialEq<R> + Reader<Offset = Offset>, Offset: PartialEq<Offset> + ReaderOffset,
impl<R, Offset> PartialEq<CommonInformationEntry<R, Offset>> for CommonInformationEntry<R, Offset>where R: PartialEq<R> + Reader<Offset = Offset>, Offset: PartialEq<Offset> + ReaderOffset,
impl<R, Offset> PartialEq<FrameDescriptionEntry<R, Offset>> for FrameDescriptionEntry<R, Offset>where R: PartialEq<R> + Reader<Offset = Offset>, Offset: PartialEq<Offset> + ReaderOffset,
impl<R, Offset> PartialEq<Location<R, Offset>> for Location<R, Offset>where R: PartialEq<R> + Reader<Offset = Offset>, Offset: PartialEq<Offset> + ReaderOffset,
impl<R, Offset> PartialEq<Operation<R, Offset>> for Operation<R, Offset>where R: PartialEq<R> + Reader<Offset = Offset>, Offset: PartialEq<Offset> + ReaderOffset,
impl<R, Offset> PartialEq<Piece<R, Offset>> for Piece<R, Offset>where R: PartialEq<R> + Reader<Offset = Offset>, Offset: PartialEq<Offset> + ReaderOffset,
impl<R, S> PartialEq<UnwindTableRow<R, S>> for UnwindTableRow<R, S>where R: PartialEq<R> + Reader, S: PartialEq<S> + UnwindContextStorage<R>,
impl<Storage> PartialEq<__BindgenBitfieldUnit<Storage>> for __BindgenBitfieldUnit<Storage>where Storage: PartialEq<Storage>,
impl<T> PartialEq<Bound<T>> for Bound<T>where T: PartialEq<T>,
impl<T> PartialEq<Option<T>> for Option<T>where T: PartialEq<T>,
impl<T> PartialEq<Poll<T>> for Poll<T>where T: PartialEq<T>,
impl<T> PartialEq<*const T> for *const Twhere T: ?Sized,
impl<T> PartialEq<*mut T> for *mut Twhere T: ?Sized,
impl<T> PartialEq<(T,)> for (T₁, T₂, …, Tₙ)where T: PartialEq<T> + ?Sized,
This trait is implemented for tuples up to twelve items long.