Trait bitintr::Rbit
[−]
[src]
pub trait Rbit { fn rbit(self) -> Self; }
Bit reverse
Required Methods
fn rbit(self) -> Self
Reverse the bit order.
Instructions
RBIT
:- Description: Reverse Bits reverses the bit order in a register.
- Architecture: ARMv7, ARMv8.
- Registers: 32 (v7) / 64 (v8) bits.
Example
assert_eq!(0b0011_0001_u8.rbit(), 0b1000_1100_u8); assert_eq!(0b0000_0000_0100_1011_u16.rbit(), 0b1101_0010_0000_0000_u16); assert_eq!( 0b11111111_u32.rbit(), 0b11111111_00000000_00000000_00000000_u32 );
Implementors
impl Rbit for u16
impl Rbit for u32
impl Rbit for u64
impl Rbit for i16
impl Rbit for i32
impl Rbit for i64
impl Rbit for u8
impl Rbit for i8