Closed
Description
Code
macro_rules! make_macro {
($macro_name:tt $($matcher:tt)*) => {
#[macro_export]
macro_rules! $macro_name [T; 0]
}
}
make_macro! {
(<= $($matcher)* =>) => {};
}
Meta
rustc --version --verbose
:
f967532a47eb728ada44473a5c4c2eca1a45fe30
Error output
The problem seems to be this:
error: macros that expand to items must be delimited with braces or followed by a semicolon (note how the `r` is green)
--> 92998.rs:4:22
|
4 | macro_rules! $macro_name [T; 0]
| ^^^^^^^^^^^
|
help: change the delimiters to curly braces
|
4 | macro_rules! {} [T; 0]
| ~
help: add a semicolon
|
4 | macro_rules! $macro_name; [T; 0]
| +
Metadata
Metadata
Assignees
Labels
Area: Messages for errors, warnings, and lintsCategory: This is a bug.Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Relevant to the compiler team, which will review and decide on the PR/issue.This issue requires a build of rustc or tooling with debug-assertions in some way