|
1 |
| -error[E0369]: cannot add `i32` to `i32` |
2 |
| - --> $DIR/minicore.rs:33:20 |
| 1 | +warning: to use a constant of type `&str` in a pattern, the type must implement `PartialEq` |
| 2 | + --> $DIR/minicore.rs:332:9 |
3 | 3 | |
|
4 |
| -LL | let x = 42_i32 + 43_i32; |
5 |
| - | ------ ^ ------ i32 |
6 |
| - | | |
7 |
| - | i32 |
| 4 | +LL | "true" => Ok(true), |
| 5 | + | ^^^^^^ |
| 6 | + | |
| 7 | + = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release! |
| 8 | + = note: for more information, see issue #116122 <https://github.com/rust-lang/rust/issues/116122> |
| 9 | + = note: `#[warn(const_patterns_without_partial_eq)]` on by default |
| 10 | + |
| 11 | +warning: to use a constant of type `&str` in a pattern, the type must implement `PartialEq` |
| 12 | + --> $DIR/minicore.rs:333:9 |
| 13 | + | |
| 14 | +LL | "false" => Ok(false), |
| 15 | + | ^^^^^^^ |
| 16 | + | |
| 17 | + = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release! |
| 18 | + = note: for more information, see issue #116122 <https://github.com/rust-lang/rust/issues/116122> |
8 | 19 |
|
9 |
| -error[E0369]: cannot add `i32` to `i32` |
10 |
| - --> $DIR/minicore.rs:37:20 |
| 20 | +error[E0493]: destructor of `Self` cannot be evaluated at compile-time |
| 21 | + --> $DIR/minicore.rs:494:9 |
11 | 22 | |
|
12 |
| -LL | let x = 42_i32 + 43_i32; |
13 |
| - | ------ ^ ------ i32 |
14 |
| - | | |
15 |
| - | i32 |
| 23 | +LL | *self = source.clone() |
| 24 | + | ^^^^^ |
| 25 | + | | |
| 26 | + | the destructor for this type cannot be evaluated in constant functions |
| 27 | + | value is dropped here |
16 | 28 |
|
17 |
| -error[E0600]: cannot apply unary operator `!` to type `bool` |
18 |
| - --> $DIR/minicore.rs:343:9 |
| 29 | +error[E0493]: destructor of `T` cannot be evaluated at compile-time |
| 30 | + --> $DIR/minicore.rs:504:35 |
19 | 31 | |
|
20 |
| -LL | !self.eq(other) |
21 |
| - | ^^^^^^^^^^^^^^^ cannot apply unary operator `!` |
| 32 | +LL | const fn drop<T: ~const Destruct>(_: T) {} |
| 33 | + | ^ - value is dropped here |
| 34 | + | | |
| 35 | + | the destructor for this type cannot be evaluated in constant functions |
22 | 36 |
|
23 |
| -error[E0600]: cannot apply unary operator `!` to type `bool` |
24 |
| - --> $DIR/minicore.rs:365:9 |
| 37 | +error: aborting due to 2 previous errors; 2 warnings emitted |
| 38 | + |
| 39 | +For more information about this error, try `rustc --explain E0493`. |
| 40 | +Future incompatibility report: Future breakage diagnostic: |
| 41 | +warning: to use a constant of type `&str` in a pattern, the type must implement `PartialEq` |
| 42 | + --> $DIR/minicore.rs:332:9 |
| 43 | + | |
| 44 | +LL | "true" => Ok(true), |
| 45 | + | ^^^^^^ |
25 | 46 | |
|
26 |
| -LL | !self |
27 |
| - | ^^^^^ cannot apply unary operator `!` |
| 47 | + = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release! |
| 48 | + = note: for more information, see issue #116122 <https://github.com/rust-lang/rust/issues/116122> |
| 49 | + = note: `#[warn(const_patterns_without_partial_eq)]` on by default |
28 | 50 |
|
29 |
| -error: aborting due to 4 previous errors |
| 51 | +Future breakage diagnostic: |
| 52 | +warning: to use a constant of type `&str` in a pattern, the type must implement `PartialEq` |
| 53 | + --> $DIR/minicore.rs:333:9 |
| 54 | + | |
| 55 | +LL | "false" => Ok(false), |
| 56 | + | ^^^^^^^ |
| 57 | + | |
| 58 | + = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release! |
| 59 | + = note: for more information, see issue #116122 <https://github.com/rust-lang/rust/issues/116122> |
| 60 | + = note: `#[warn(const_patterns_without_partial_eq)]` on by default |
30 | 61 |
|
31 |
| -Some errors have detailed explanations: E0369, E0600. |
32 |
| -For more information about an error, try `rustc --explain E0369`. |
|
0 commit comments