type BorrowsDomain = DenseBitSet<BorrowIndex>;
Aliased Type§
struct BorrowsDomain { /* private fields */ }
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 32 bytes
Implementations
Source§impl<T> DenseBitSet<T>
impl<T> DenseBitSet<T>
Sourcepub fn domain_size(&self) -> usize
pub fn domain_size(&self) -> usize
Gets the domain size.
Source§impl<T> DenseBitSet<T>where
T: Idx,
impl<T> DenseBitSet<T>where
T: Idx,
Sourcepub fn new_empty(domain_size: usize) -> DenseBitSet<T>
pub fn new_empty(domain_size: usize) -> DenseBitSet<T>
Creates a new, empty bitset with a given domain_size
.
Sourcepub fn new_filled(domain_size: usize) -> DenseBitSet<T>
pub fn new_filled(domain_size: usize) -> DenseBitSet<T>
Creates a new, filled bitset with a given domain_size
.
Sourcepub fn superset(&self, other: &DenseBitSet<T>) -> bool
pub fn superset(&self, other: &DenseBitSet<T>) -> bool
Is self
is a (non-strict) superset of other
?
pub fn insert_range(&mut self, elems: impl RangeBounds<T>)
Sourcepub fn insert_all(&mut self)
pub fn insert_all(&mut self)
Sets all bits to true.
pub fn last_set_in(&self, range: impl RangeBounds<T>) -> Option<T>
Sourcepub fn union<Rhs>(&mut self, other: &Rhs) -> boolwhere
DenseBitSet<T>: BitRelations<Rhs>,
pub fn union<Rhs>(&mut self, other: &Rhs) -> boolwhere
DenseBitSet<T>: BitRelations<Rhs>,
Sets self = self | other
and returns true
if self
changed
(i.e., if new bits were added).
Sourcepub fn subtract<Rhs>(&mut self, other: &Rhs) -> boolwhere
DenseBitSet<T>: BitRelations<Rhs>,
pub fn subtract<Rhs>(&mut self, other: &Rhs) -> boolwhere
DenseBitSet<T>: BitRelations<Rhs>,
Sets self = self - other
and returns true
if self
changed.
(i.e., if any bits were removed).
Sourcepub fn intersect<Rhs>(&mut self, other: &Rhs) -> boolwhere
DenseBitSet<T>: BitRelations<Rhs>,
pub fn intersect<Rhs>(&mut self, other: &Rhs) -> boolwhere
DenseBitSet<T>: BitRelations<Rhs>,
Sets self = self & other
and return true
if self
changed.
(i.e., if any bits were removed).
Sourcepub fn union_not(&mut self, other: &DenseBitSet<T>)
pub fn union_not(&mut self, other: &DenseBitSet<T>)
Sets self = self | !other
.
FIXME: Incorporate this into BitRelations
and fill out
implementations for other bitset types, if needed.
Trait Implementations
Source§impl<T> BitRelations<ChunkedBitSet<T>> for DenseBitSet<T>where
T: Idx,
impl<T> BitRelations<ChunkedBitSet<T>> for DenseBitSet<T>where
T: Idx,
fn union(&mut self, other: &ChunkedBitSet<T>) -> bool
fn subtract(&mut self, _other: &ChunkedBitSet<T>) -> bool
fn intersect(&mut self, other: &ChunkedBitSet<T>) -> bool
Source§impl<T> BitRelations<DenseBitSet<T>> for DenseBitSet<T>where
T: Idx,
impl<T> BitRelations<DenseBitSet<T>> for DenseBitSet<T>where
T: Idx,
fn union(&mut self, other: &DenseBitSet<T>) -> bool
fn subtract(&mut self, other: &DenseBitSet<T>) -> bool
fn intersect(&mut self, other: &DenseBitSet<T>) -> bool
Source§impl<T> Clone for DenseBitSet<T>
impl<T> Clone for DenseBitSet<T>
Source§fn clone(&self) -> DenseBitSet<T>
fn clone(&self) -> DenseBitSet<T>
Source§fn clone_from(&mut self, from: &DenseBitSet<T>)
fn clone_from(&mut self, from: &DenseBitSet<T>)
source
. Read moreSource§impl<T> Debug for DenseBitSet<T>where
T: Idx,
impl<T> Debug for DenseBitSet<T>where
T: Idx,
Source§impl<T, C> DebugWithContext<C> for DenseBitSet<T>where
T: Idx + DebugWithContext<C>,
impl<T, C> DebugWithContext<C> for DenseBitSet<T>where
T: Idx + DebugWithContext<C>,
Source§impl<T, __D> Decodable<__D> for DenseBitSet<T>
impl<T, __D> Decodable<__D> for DenseBitSet<T>
fn decode(__decoder: &mut __D) -> DenseBitSet<T>
Source§impl<T, __E> Encodable<__E> for DenseBitSet<T>
impl<T, __E> Encodable<__E> for DenseBitSet<T>
Source§impl<T> From<GrowableBitSet<T>> for DenseBitSet<T>where
T: Idx,
impl<T> From<GrowableBitSet<T>> for DenseBitSet<T>where
T: Idx,
Source§fn from(bit_set: GrowableBitSet<T>) -> DenseBitSet<T>
fn from(bit_set: GrowableBitSet<T>) -> DenseBitSet<T>
Source§impl<T> GenKill<T> for DenseBitSet<T>where
T: Idx,
impl<T> GenKill<T> for DenseBitSet<T>where
T: Idx,
Source§fn gen_all(&mut self, elems: impl IntoIterator<Item = T>)
fn gen_all(&mut self, elems: impl IntoIterator<Item = T>)
gen
for each element in elems
.Source§fn kill_all(&mut self, elems: impl IntoIterator<Item = T>)
fn kill_all(&mut self, elems: impl IntoIterator<Item = T>)
kill
for each element in elems
.Source§impl<T> Hash for DenseBitSet<T>where
T: Hash,
impl<T> Hash for DenseBitSet<T>where
T: Hash,
Source§impl<I, CTX> HashStable<CTX> for DenseBitSet<I>where
I: Idx,
impl<I, CTX> HashStable<CTX> for DenseBitSet<I>where
I: Idx,
fn hash_stable(&self, _ctx: &mut CTX, hasher: &mut StableHasher<SipHasher128>)
Source§impl<T> JoinSemiLattice for DenseBitSet<T>where
T: Idx,
A DenseBitSet
represents the lattice formed by the powerset of all possible values of the
index type T
ordered by inclusion. Equivalently, it is a tuple of “two-point” lattices, one
for each possible value of T
.
impl<T> JoinSemiLattice for DenseBitSet<T>where
T: Idx,
A DenseBitSet
represents the lattice formed by the powerset of all possible values of the
index type T
ordered by inclusion. Equivalently, it is a tuple of “two-point” lattices, one
for each possible value of T
.