about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/test/compile-fail/const-eval-overflow-3.rs8
-rw-r--r--src/test/compile-fail/const-eval-overflow-3b.rs11
-rw-r--r--src/test/compile-fail/huge-array-simple.rs9
3 files changed, 18 insertions, 10 deletions
diff --git a/src/test/compile-fail/const-eval-overflow-3.rs b/src/test/compile-fail/const-eval-overflow-3.rs
index 7d84562c6bd..c2bc5b2648a 100644
--- a/src/test/compile-fail/const-eval-overflow-3.rs
+++ b/src/test/compile-fail/const-eval-overflow-3.rs
@@ -13,6 +13,12 @@
 //
 // This test is checking the count in an array expression.
 
+// FIXME (#23926): the error output is not consistent between a
+// self-hosted and a cross-compiled setup; therefore resorting to
+// error-pattern for now.
+
+// error-pattern: expected constant integer for repeat count, but attempted to add with overflow
+
 #![allow(unused_imports)]
 
 use std::fmt;
@@ -22,8 +28,6 @@ use std::{u8, u16, u32, u64, usize};
 const A_I8_I
     : [u32; (i8::MAX as usize) + 1]
     = [0; (i8::MAX + 1) as usize];
-//~^ ERROR mismatched types
-//~| ERROR expected constant integer for repeat count, but attempted to add with overflow
 
 fn main() {
     foo(&A_I8_I[..]);
diff --git a/src/test/compile-fail/const-eval-overflow-3b.rs b/src/test/compile-fail/const-eval-overflow-3b.rs
index 950620fe019..719b21000f7 100644
--- a/src/test/compile-fail/const-eval-overflow-3b.rs
+++ b/src/test/compile-fail/const-eval-overflow-3b.rs
@@ -17,6 +17,12 @@
 // types for the left- and right-hand sides of the addition do not
 // match (as well as overflow).
 
+// FIXME (#23926): the error output is not consistent between a
+// self-hosted and a cross-compiled setup; therefore resorting to
+// error-pattern for now.
+
+// error-pattern: mismatched types
+
 #![allow(unused_imports)]
 
 use std::fmt;
@@ -26,11 +32,6 @@ use std::{u8, u16, u32, u64, usize};
 const A_I8_I
     : [u32; (i8::MAX as usize) + 1]
     = [0; (i8::MAX + 1u8) as usize];
-//~^ ERROR mismatched types
-//~| ERROR mismatched types
-//~| ERROR expected constant integer for repeat count, but attempted to add with overflow
-//~| ERROR the trait `core::ops::Add<u8>` is not implemented for the type `i8`
-//~| ERROR the trait `core::ops::Add<u8>` is not implemented for the type `i8`
 
 fn main() {
     foo(&A_I8_I[..]);
diff --git a/src/test/compile-fail/huge-array-simple.rs b/src/test/compile-fail/huge-array-simple.rs
index e6446304177..54340cf7ac4 100644
--- a/src/test/compile-fail/huge-array-simple.rs
+++ b/src/test/compile-fail/huge-array-simple.rs
@@ -8,11 +8,14 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// FIXME (#23926): the error output is not consistent between a
+// self-hosted and a cross-compiled setup. Skipping for now.
+
+// ignore-test FIXME(#23926)
+
 #![allow(exceeding_bitshifts)]
 
 fn main() {
-    let fat : [u8; (1<<61)+(1<<31)] =
-        //~^ ERROR array length constant evaluation error: attempted left shift with overflow
+    let _fat : [u8; (1<<61)+(1<<31)] =
         [0; (1u64<<61) as usize +(1u64<<31) as usize];
-    //~^ ERROR expected constant integer for repeat count, but attempted left shift with overflow
 }