pub trait StructuralEq {
// Required method
fn structural_eq(&self, other: &Self) -> bool;
}Required Methods§
Sourcefn structural_eq(&self, other: &Self) -> bool
fn structural_eq(&self, other: &Self) -> bool
Check if two values are equal, ignoring the type.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementations on Foreign Types§
Source§impl<T: StructuralEq> StructuralEq for Option<T>
impl<T: StructuralEq> StructuralEq for Option<T>
fn structural_eq(&self, other: &Self) -> bool
Implementors§
impl StructuralEq for TypeDefinition
impl StructuralEq for StructuralTypeDefinition
impl StructuralEq for CoreValue
impl StructuralEq for Decimal
impl StructuralEq for TypedDecimal
impl StructuralEq for TypedInteger
impl StructuralEq for BorrowedMapKey<'_>
impl StructuralEq for Map
impl StructuralEq for ValueContainer
Structural equality checks the structural equality of the underlying values, collapsing references to their current resolved values.
impl StructuralEq for Boolean
impl StructuralEq for Callable
impl StructuralEq for Endpoint
impl StructuralEq for Integer
impl StructuralEq for List
impl StructuralEq for Text
impl StructuralEq for Type
impl StructuralEq for Value
Two values are structurally equal, if their inner values are structurally equal, regardless of the actual_type of the values