Skip to content

Commit 42409f0

Browse files
committed
Rename Mask::from_int to Mask::from_simd
1 parent 1e62d4c commit 42409f0

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

crates/core_simd/src/masks.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ where
204204
#[inline]
205205
#[must_use = "method returns a new mask and does not mutate the original value"]
206206
#[track_caller]
207-
pub fn from_int(value: Simd<T, N>) -> Self {
207+
pub fn from_simd(value: Simd<T, N>) -> Self {
208208
assert!(T::valid(value), "all values must be either 0 or -1",);
209209
// Safety: the validity has been checked
210210
unsafe { Self::from_int_unchecked(value) }

crates/core_simd/tests/masks.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ macro_rules! test_mask_api {
6767
let mask = Mask::<$type, 8>::from_array(values);
6868
let int = mask.to_simd();
6969
assert_eq!(int.to_array(), [-1, 0, 0, -1, 0, 0, -1, 0]);
70-
assert_eq!(Mask::<$type, 8>::from_int(int), mask);
70+
assert_eq!(Mask::<$type, 8>::from_simd(int), mask);
7171
}
7272

7373
#[test]

0 commit comments

Comments
 (0)