//@ check-fail #![feature(repr_simd, intrinsics)] extern "rust-intrinsic" { fn simd_masked_load(mask: M, pointer: P, values: T) -> T; fn simd_masked_store(mask: M, pointer: P, values: T) -> (); } #[derive(Copy, Clone)] #[repr(simd)] struct Simd([T; N]); fn main() { unsafe { let mut arr = [4u8, 5, 6, 7]; let default = Simd::([9; 4]); let _x: Simd = simd_masked_load( Simd::([-1, 0, -1, -1]), arr.as_ptr(), Simd::([9; 4]) ); //~^^ ERROR mismatched types let _x: Simd = simd_masked_load( Simd::([1, 0, 1, 1]), arr.as_ptr(), default ); //~^^ ERROR mismatched types } }