Skip to main content

ContextOrd

Trait ContextOrd 

Source
pub trait ContextOrd<Ctx> {
    // Provided method
    fn stable_cmp_with_context(
        _context: Ctx,
    ) -> impl FnMut(&Self, &Self) -> Ordering { ... }
}

Provided Methods§

Source

fn stable_cmp_with_context( _context: Ctx, ) -> impl FnMut(&Self, &Self) -> Ordering

The returned comparator must be stable. E. g. compares DefPathHash instead of DefIndex

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<Ctx> ContextOrd<Ctx> for String

Source§

fn stable_cmp_with_context( _context: Ctx, ) -> impl FnMut(&Self, &Self) -> Ordering

Source§

impl<Ctx> ContextOrd<Ctx> for i64

Source§

impl<Ctx> ContextOrd<Ctx> for u32

Implementors§