summaryrefslogtreecommitdiffstats
path: root/tests/ui/simd/type-generic-monomorphisation-oversized.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/simd/type-generic-monomorphisation-oversized.rs')
-rw-r--r--tests/ui/simd/type-generic-monomorphisation-oversized.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/ui/simd/type-generic-monomorphisation-oversized.rs b/tests/ui/simd/type-generic-monomorphisation-oversized.rs
new file mode 100644
index 000000000..a7dc482f3
--- /dev/null
+++ b/tests/ui/simd/type-generic-monomorphisation-oversized.rs
@@ -0,0 +1,12 @@
+// build-fail
+
+#![feature(repr_simd, platform_intrinsics)]
+
+// error-pattern:monomorphising SIMD type `Simd<65536>` of length greater than 32768
+
+#[repr(simd)]
+struct Simd<const N: usize>([f32; N]);
+
+fn main() {
+ let _ = Simd::<65536>([0.; 65536]);
+}