pub fn boolean_vector_switch_le_be(bits: &[Boolean]) -> Vec<Boolean> {
    assert_eq!(bits.len() % 8, 0);

    bits.chunks(8)
        .flat_map(|byte| byte.iter().rev())
        .cloned()
        .collect()
}
/// Convert a boolean vector from big to little endian format or vice versa.
Convert a boolean vector from big to little endian format or vice versa.
Convert a boolean vector from big to little endian format or vice versa .
pub fn boolean_vector_switch_le_be(bits: &[Boolean]) -> Vec<Boolean> {
    assert_eq!(bits.len() % 8, 0);
    bits.chunks(8)
        .flat_map(|byte| byte.iter().rev())
        .cloned()
        .collect()
}
pub fn boolean_vector_switch_le_be ( bits : & [ Boolean ] ) -> Vec < Boolean > { assert_eq ! ( bits len ( ) 8 0 ) ; bits . chunks ( 8 ) . flat_map ( | byte | byte . iter ( ) . rev ( ) ) . cloned ( ) . collect ( ) }
Convert a boolean vector from big to little endian format or vice versa.
Convert a boolean vector from big to little endian format or vice versa .
bits
&[Boolean]
bits
&[Boolean]