Closed
Description
The following code will cause the compiler to fail:
macro_rules! ex {
($($(i:ident)?)+) => { };
}
fn main() {
ex!();
}
Playground link: https://play.rust-lang.org/?version=beta&mode=debug&edition=2018&gist=acce7614d74028b67c92a79b50b93522
It should error that the inner matcher can match an empty string and reject it, just as it does if *
is used in place of ?
.