Enum MixedBitSet
pub enum MixedBitSet<T> {
Small(DenseBitSet<T>),
Large(ChunkedBitSet<T>),
}
Expand description
A bitset with a mixed representation, using DenseBitSet
for small and
medium bitsets, and ChunkedBitSet
for large bitsets, i.e. those with
enough bits for at least two chunks. This is a good choice for many bitsets
that can have large domain sizes (e.g. 5000+).
T
is an index type, typically a newtyped usize
wrapper, but it can also
just be usize
.
All operations that involve an element will panic if the element is equal to or greater than the domain size. All operations that involve two bitsets will panic if the bitsets have differing domain sizes.
Variants§
Small(DenseBitSet<T>)
Large(ChunkedBitSet<T>)
Auto Trait Implementations§
impl<T> Freeze for MixedBitSet<T>
impl<T> RefUnwindSafe for MixedBitSet<T>where
T: RefUnwindSafe,
impl<T> !Send for MixedBitSet<T>
impl<T> !Sync for MixedBitSet<T>
impl<T> Unpin for MixedBitSet<T>where
T: Unpin,
impl<T> UnwindSafe for MixedBitSet<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more