We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 357e052 commit 5c16856Copy full SHA for 5c16856
src/block/default.rs
@@ -11,6 +11,16 @@ impl Block {
11
pub const ALL: Self = Block(!0);
12
pub const BITS: usize = core::mem::size_of::<Self>() * 8;
13
14
+ #[inline]
15
+ pub fn into_usize_array(self) -> [usize; Self::USIZE_COUNT] {
16
+ [self.0]
17
+ }
18
+
19
20
+ pub const fn from_usize_array(array: [usize; Self::USIZE_COUNT]) -> Self {
21
+ Self(array[0])
22
23
24
#[inline]
25
pub const fn is_empty(self) -> bool {
26
self.0 == Self::NONE.0
0 commit comments