-
Notifications
You must be signed in to change notification settings - Fork 13.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rollup merge of #131522 - c410-f3r:unlock-rfc-2011, r=chenyukang
[macro_metavar_expr_concat] Fix #128346 Fix #128346 Fix #131393 The syntax is invalid in both issues so I guess that theoretically the compiler should have aborted early. This PR tries to fix a local problem but let me know if there are better options. cc `@petrochenkov` if you are interested
- Loading branch information
Showing
4 changed files
with
46 additions
and
17 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 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
22 changes: 22 additions & 0 deletions
22
tests/ui/macros/macro-metavar-expr-concat/repetitions.stderr
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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
error: invalid syntax | ||
--> $DIR/repetitions.rs:14:20 | ||
| | ||
LL | const ${concat($a, Z)}: i32 = 3; | ||
| ^^^^^^^^^^^^^^^ | ||
|
||
error: invalid syntax | ||
--> $DIR/repetitions.rs:22:17 | ||
| | ||
LL | read::<${concat($t, $en)}>() | ||
| ^^^^^^^^^^^^^^^^^ | ||
|
||
error: invalid syntax | ||
--> $DIR/repetitions.rs:22:17 | ||
| | ||
LL | read::<${concat($t, $en)}>() | ||
| ^^^^^^^^^^^^^^^^^ | ||
| | ||
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no` | ||
|
||
error: aborting due to 3 previous errors | ||
|