]> git.lizzy.rs Git - rust.git/blob - tests/ui/consts/const-eval/const-eval-overflow-2.stderr
Rollup merge of #106714 - Ezrashaw:remove-e0490, r=davidtwco
[rust.git] / tests / ui / consts / const-eval / const-eval-overflow-2.stderr
1 error[E0080]: evaluation of constant value failed
2   --> $DIR/const-eval-overflow-2.rs:11:25
3    |
4 LL | const NEG_NEG_128: i8 = -NEG_128;
5    |                         ^^^^^^^^ attempt to negate `i8::MIN`, which would overflow
6
7 error: could not evaluate constant pattern
8   --> $DIR/const-eval-overflow-2.rs:15:9
9    |
10 LL |         NEG_NEG_128 => println!("A"),
11    |         ^^^^^^^^^^^
12
13 error: could not evaluate constant pattern
14   --> $DIR/const-eval-overflow-2.rs:15:9
15    |
16 LL |         NEG_NEG_128 => println!("A"),
17    |         ^^^^^^^^^^^
18
19 error: aborting due to 3 previous errors
20
21 For more information about this error, try `rustc --explain E0080`.