RangeExt

Trait RangeExt 

Source
pub trait RangeExt {
    // Required method
    fn intersect(&self, rhs: &Self) -> Self;
}
Expand description

Provides convenience methods for Range.

Required Methods§

Source

fn intersect(&self, rhs: &Self) -> Self

Returns the intersection of self and rhs. If there is no intersection, the result will return true for .is_empty().

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.

Implementors§

Source§

impl<K: Ord + Copy> RangeExt for Range<K>