rust/tests/ui/macros/macro-match-nonterminal.rs
Trevor Gross b9e9be38c0 mbe: Clean up code with non-optional NonterminalKind
Since [1], the fragment specifier is unconditionally required in all
editions. This means `NonTerminalKind` no longer needs to be optional,
as we can reject this code during the expansion of `macro_rules!` rather
than handling it throughout the code. Do this cleanup here.

[1]: https://github.com/rust-lang/rust/pull/128425
2025-06-24 04:37:36 -04:00

12 lines
202 B
Rust

macro_rules! test {
($a, $b) => {
//~^ ERROR missing fragment
//~| ERROR missing fragment
()
};
}
fn main() {
test!() //~ ERROR unexpected end of macro invocation
}