|
1 | | -warning: literal out of range for `i8` |
2 | | - --> $DIR/lint-type-overflow2.rs:9:20 |
| 1 | +error: literal out of range for `i8` |
| 2 | + --> $DIR/lint-type-overflow2.rs:8:20 |
3 | 3 | | |
4 | 4 | LL | let x2: i8 = --128; |
5 | 5 | | ^^^ |
6 | 6 | | |
7 | 7 | note: lint level defined here |
8 | | - --> $DIR/lint-type-overflow2.rs:2:9 |
| 8 | + --> $DIR/lint-type-overflow2.rs:3:9 |
9 | 9 | | |
10 | | -LL | #![warn(overflowing_literals)] |
| 10 | +LL | #![deny(overflowing_literals)] |
11 | 11 | | ^^^^^^^^^^^^^^^^^^^^ |
12 | 12 |
|
13 | | -warning: literal out of range for `f32` |
14 | | - --> $DIR/lint-type-overflow2.rs:11:14 |
| 13 | +error: literal out of range for `f32` |
| 14 | + --> $DIR/lint-type-overflow2.rs:10:14 |
15 | 15 | | |
16 | 16 | LL | let x = -3.40282357e+38_f32; |
17 | 17 | | ^^^^^^^^^^^^^^^^^^ |
18 | 18 |
|
19 | | -warning: literal out of range for `f32` |
20 | | - --> $DIR/lint-type-overflow2.rs:12:14 |
| 19 | +error: literal out of range for `f32` |
| 20 | + --> $DIR/lint-type-overflow2.rs:11:14 |
21 | 21 | | |
22 | 22 | LL | let x = 3.40282357e+38_f32; |
23 | 23 | | ^^^^^^^^^^^^^^^^^^ |
24 | 24 |
|
25 | | -warning: literal out of range for `f64` |
26 | | - --> $DIR/lint-type-overflow2.rs:13:14 |
| 25 | +error: literal out of range for `f64` |
| 26 | + --> $DIR/lint-type-overflow2.rs:12:14 |
27 | 27 | | |
28 | 28 | LL | let x = -1.7976931348623159e+308_f64; |
29 | 29 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
30 | 30 |
|
31 | | -warning: literal out of range for `f64` |
32 | | - --> $DIR/lint-type-overflow2.rs:14:14 |
| 31 | +error: literal out of range for `f64` |
| 32 | + --> $DIR/lint-type-overflow2.rs:13:14 |
33 | 33 | | |
34 | 34 | LL | let x = 1.7976931348623159e+308_f64; |
35 | 35 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
36 | 36 |
|
37 | | -warning: this expression will panic at runtime |
38 | | - --> $DIR/lint-type-overflow2.rs:9:18 |
39 | | - | |
40 | | -LL | let x2: i8 = --128; |
41 | | - | ^^^^^ attempt to negate with overflow |
42 | | - | |
43 | | -note: lint level defined here |
44 | | - --> $DIR/lint-type-overflow2.rs:3:9 |
45 | | - | |
46 | | -LL | #![warn(const_err)] |
47 | | - | ^^^^^^^^^ |
| 37 | +error: aborting due to 5 previous errors |
48 | 38 |
|
0 commit comments