[][src]Trait lrl_test_compiler::bits::BitSource

pub trait BitSource {
    const LEN: u8;

    fn slice(&self, offset: u8, len: u8) -> u8;

    fn slice_left(&self, offset: u8, len: u8, margin: u8) -> u8 { ... }
}
[]

A BitSource is something that can have bits read from it

Associated Constants

const LEN: u8[]

The length of the BitSource in bits

Required methods

fn slice(&self, offset: u8, len: u8) -> u8[]

Selects the range of bits described by [offset .. offset+len] Returns these bits right-aligned in a u8

Provided methods

fn slice_left(&self, offset: u8, len: u8, margin: u8) -> u8[]

Selects the range of bits described by [offset .. offset+len] Returns these bits left-aligned in a u8, preceded by the amount of margin

Implementations on Foreign Types

impl BitSource for u8[src][]

impl BitSource for u16[src][]

impl BitSource for u32[src][]

impl BitSource for u64[src][]

impl BitSource for u128[src][]

Implementors