Update tests after pretty printing
This commit is contained in:
parent
cfa1f80cd9
commit
f865b7dda4
@ -4,6 +4,6 @@
|
||||
use std::fmt::Debug;
|
||||
|
||||
#[derive(Debug)]
|
||||
struct S<T: Debug, const N: usize>([T; N]); //~ ERROR `[T; N]` doesn't implement `std::fmt::Debug`
|
||||
struct S<T: Debug, const N: usize>([T; N]); //~ ERROR `[T; _]` doesn't implement `std::fmt::Debug`
|
||||
|
||||
fn main() {}
|
||||
|
@ -4,14 +4,14 @@ warning: the feature `const_generics` is incomplete and may cause the compiler t
|
||||
LL | #![feature(const_generics)]
|
||||
| ^^^^^^^^^^^^^^
|
||||
|
||||
error[E0277]: `[T; N]` doesn't implement `std::fmt::Debug`
|
||||
error[E0277]: `[T; _]` doesn't implement `std::fmt::Debug`
|
||||
--> $DIR/broken-mir-2.rs:7:36
|
||||
|
|
||||
LL | struct S<T: Debug, const N: usize>([T; N]);
|
||||
| ^^^^^^ `[T; N]` cannot be formatted using `{:?}` because it doesn't implement `std::fmt::Debug`
|
||||
| ^^^^^^ `[T; _]` cannot be formatted using `{:?}` because it doesn't implement `std::fmt::Debug`
|
||||
|
|
||||
= help: the trait `std::fmt::Debug` is not implemented for `[T; N]`
|
||||
= note: required because of the requirements on the impl of `std::fmt::Debug` for `&[T; N]`
|
||||
= help: the trait `std::fmt::Debug` is not implemented for `[T; _]`
|
||||
= note: required because of the requirements on the impl of `std::fmt::Debug` for `&[T; _]`
|
||||
= note: required for the cast to the object type `dyn std::fmt::Debug`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
@ -14,7 +14,7 @@ error[E0308]: mismatched types
|
||||
--> $DIR/cannot-infer-type-for-const-param.rs:10:22
|
||||
|
|
||||
LL | let _ = Foo::<3>([1, 2, 3]);
|
||||
| ^^^^^^^^^ expected `Const { ty: usize, val: Unevaluated(DefId(0:18 ~ cannot_infer_type_for_const_param[317d]::main[0]::{{constant}}[0]), []) }`, found `Const { ty: usize, val: Scalar(Bits { size: 8, bits: 3 }) }`
|
||||
| ^^^^^^^^^ expected `Const { ty: usize, val: Unevaluated(DefId(0:18 ~ cannot_infer_type_for_const_param[317d]::main[0]::{{constant}}[0]), []) }`, found `Const { ty: usize, val: Scalar(0x0000000000000003) }`
|
||||
|
|
||||
= note: expected type `[u8; _]`
|
||||
found type `[u8; 3]`
|
||||
|
@ -2,7 +2,7 @@ error[E0308]: mismatched types
|
||||
--> $DIR/const-array-oob-arith.rs:7:45
|
||||
|
|
||||
LL | const BLUB: [i32; (ARR[0] - 40) as usize] = [5];
|
||||
| ^^^ expected `Const { ty: usize, val: Scalar(Bits { size: 8, bits: 2 }) }`, found `Const { ty: usize, val: Scalar(Bits { size: 8, bits: 1 }) }`
|
||||
| ^^^ expected `Const { ty: usize, val: Scalar(0x0000000000000002) }`, found `Const { ty: usize, val: Scalar(0x0000000000000001) }`
|
||||
|
|
||||
= note: expected type `[i32; 2]`
|
||||
found type `[i32; 1]`
|
||||
@ -11,7 +11,7 @@ error[E0308]: mismatched types
|
||||
--> $DIR/const-array-oob-arith.rs:8:44
|
||||
|
|
||||
LL | const BOO: [i32; (ARR[0] - 41) as usize] = [5, 99];
|
||||
| ^^^^^^^ expected `Const { ty: usize, val: Scalar(Bits { size: 8, bits: 1 }) }`, found `Const { ty: usize, val: Scalar(Bits { size: 8, bits: 2 }) }`
|
||||
| ^^^^^^^ expected `Const { ty: usize, val: Scalar(0x0000000000000001) }`, found `Const { ty: usize, val: Scalar(0x0000000000000002) }`
|
||||
|
|
||||
= note: expected type `[i32; 1]`
|
||||
found type `[i32; 2]`
|
||||
|
Loading…
x
Reference in New Issue
Block a user