blob: ce2911de986dc03b8bf17eca58abe9cbf21b9d49 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
// run-pass
// edition:2018
macro_rules! pat_bar {
($p:pat | $p2:pat) => {{
match Some(1u8) {
$p | $p2 => {}
_ => {}
}
}};
}
fn main() {
pat_bar!(Some(1u8) | None);
}
|