blob: c8d41459383acddb93ca5b7d78332180a0e72806 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
//@ check-pass
// Make sure that a `stmt` nonterminal does not eagerly match against
// a `pat`, since this will always cause a parse error...
macro_rules! m {
($pat:pat) => {};
($stmt:stmt) => {};
}
macro_rules! m2 {
($stmt:stmt) => {
m! { $stmt }
};
}
m2! { let x = 1 }
fn main() {}
|