pub trait OneSidedRange<T>: RangeBounds<T> { / Required method fn bound(self) -> (OneSidedRangeBound, T); }
one_sided_range
OneSidedRange is implemented for built-in range types that are unbounded on one side. For example, a.., ..b and ..=c implement OneSidedRange, but .., d..e, and f..=g do not.
OneSidedRange
a..
..b
..=c
..
d..e
f..=g
Types that implement OneSidedRange<T> must return Bound::Unbounded from one of RangeBounds::start_bound or RangeBounds::end_bound.
OneSidedRange<T>
Bound::Unbounded
RangeBounds::start_bound
RangeBounds::end_bound
An internal-only helper function for split_off and split_off_mut that returns the bound of the one-sided range.
split_off
split_off_mut
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.