Module bitvec::order [−][src]
Expand description
Ordering of bits within register elements.
bitvec
structures are parametric over any ordering of bits within a register.
The BitOrder
trait maps a cursor position (indicated by the BitIdx
type) to an
electrical position (indicated by the BitPos
type) within that element, and
also defines the order of traversal over a register.
The only requirement on implementors of BitOrder
is that the transform function
from cursor (BitIdx
) to position (BitPos
) is total (every integer in the
domain 0 .. T::BITS
is used) and unique (each cursor maps to one and only
one position, and each position is mapped by one and only one cursor).
Contiguity is not required.
BitOrder
is a stateless trait, and implementors should be zero-sized types.
!
Structs
Traits
An ordering over a register.
Type Definitions
A default bit ordering.