-
Notifications
You must be signed in to change notification settings - Fork 13k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove the coerce_never lint and make the behaviour an error.
- Loading branch information
1 parent
32601f6
commit c3beef6
Showing
12 changed files
with
21 additions
and
101 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,20 @@ | ||
error[E0600]: cannot apply unary operator `!` to type `!` | ||
--> $DIR/expr_unary.rs:17:16 | ||
| | ||
17 | let x: ! = ! { return; }; //~ ERROR unreachable | ||
| ^^^^^^^^^^^^^ | ||
|
||
error: unreachable expression | ||
--> $DIR/expr_unary.rs:18:28 | ||
--> $DIR/expr_unary.rs:17:16 | ||
| | ||
18 | let x: ! = ! { return; 22 }; //~ ERROR unreachable | ||
| ^^ | ||
17 | let x: ! = ! { return; }; //~ ERROR unreachable | ||
| ^^^^^^^^^^^^^ | ||
| | ||
note: lint level defined here | ||
--> $DIR/expr_unary.rs:14:9 | ||
| | ||
14 | #![deny(unreachable_code)] | ||
| ^^^^^^^^^^^^^^^^ | ||
|
||
error: cannot coerce `{integer}` to ! | ||
--> $DIR/expr_unary.rs:18:28 | ||
| | ||
18 | let x: ! = ! { return; 22 }; //~ ERROR unreachable | ||
| ^^ | ||
| | ||
note: lint level defined here | ||
--> $DIR/expr_unary.rs:15:9 | ||
| | ||
15 | #![deny(coerce_never)] | ||
| ^^^^^^^^^^^^ | ||
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release! | ||
= note: for more information, see issue #46325 <https://github.com/rust-lang/rust/issues/46325> | ||
|
||
error[E0600]: cannot apply unary operator `!` to type `!` | ||
--> $DIR/expr_unary.rs:18:16 | ||
| | ||
18 | let x: ! = ! { return; 22 }; //~ ERROR unreachable | ||
| ^^^^^^^^^^^^^^^^ | ||
|
||
error: aborting due to 3 previous errors | ||
error: aborting due to 2 previous errors | ||
|