Module bit_set

Source

Macros§

bit_relations_inherent_impls 🔒

Structs§

BitIter
BitMatrix
A fixed-size 2D bit matrix type with a dense representation.
ChunkedBitIter
ChunkedBitSet
A fixed-size bitset type with a partially dense, partially sparse representation. The bitset is broken into chunks, and chunks that are all zeros or all ones are represented and handled very efficiently.
DenseBitSet
A fixed-size bitset type with a dense representation.
FiniteBitSet
A fixed-sized bitset type represented by an integer type. Indices outwith than the range representable by T are considered set.
GrowableBitSet
A resizable bitset type with a dense representation.
SparseBitMatrix
A fixed-column-size, variable-row-size 2D bit matrix with a moderately sparse representation.

Enums§

Chunk 🔒
ChunkIter 🔒
MixedBitIter
MixedBitSet
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+).

Constants§

CHUNK_BITS 🔒
CHUNK_WORDS 🔒
WORD_BITS 🔒
WORD_BYTES 🔒

Traits§

BitRelations
FiniteBitSetTy
Integral type used to represent the bit set.

Functions§

bitwise 🔒
Sets out_vec[i] = op(out_vec[i], in_vec[i]) for each index i in both slices. The slices must have the same length.
bitwise_changes 🔒
Does this bitwise operation change out_vec?
chunk_index 🔒
chunk_word_index_and_mask 🔒
clear_excess_bits_in_final_word 🔒
inclusive_start_end 🔒
max_bit 🔒
num_chunks 🔒
num_words 🔒
sequential_update 🔒
word_index_and_mask 🔒

Type Aliases§

ChunkSize 🔒
ChunkSize is small to keep Chunk small. The static assertion ensures it’s not too small.
Word 🔒