pub trait SliceBitAndAssign<T>: Slice<Item = T> {
// Required methods
const fn bitand_assign_all<Rhs>(&mut self, rhs: Rhs)
where T: BitAndAssign<Rhs>,
Rhs: Copy;
const async fn bitand_assign_all_async<Rhs>(&mut self, rhs: Rhs)
where T: BitAndAssign<Rhs>,
Rhs: Copy;
}Required Methods§
Sourceconst fn bitand_assign_all<Rhs>(&mut self, rhs: Rhs)where
T: BitAndAssign<Rhs>,
Rhs: Copy,
const fn bitand_assign_all<Rhs>(&mut self, rhs: Rhs)where
T: BitAndAssign<Rhs>,
Rhs: Copy,
Performs a bitwise AND on each element using rhs.
§Example
use slice_ops::ops::*;
let mut x = [0b1, 0b10, 0b11, 0b100, 0b101, 0b110, 0b111, 0b1000];
x.bitand_assign_all(0b10);
assert_eq!(x, [0b0, 0b10, 0b10, 0b0, 0b0, 0b10, 0b10, 0b0]);Sourceconst async fn bitand_assign_all_async<Rhs>(&mut self, rhs: Rhs)where
T: BitAndAssign<Rhs>,
Rhs: Copy,
const async fn bitand_assign_all_async<Rhs>(&mut self, rhs: Rhs)where
T: BitAndAssign<Rhs>,
Rhs: Copy,
Asynchronously performs a bitwise AND on each element using rhs.
§Example
use slice_ops::ops::*;
let mut x = [0b1, 0b10, 0b11, 0b100, 0b101, 0b110, 0b111, 0b1000];
x.bitand_assign_all_async(0b10).await;
assert_eq!(x, [0b0, 0b10, 0b10, 0b0, 0b0, 0b10, 0b10, 0b0]);Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.