mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-29 20:46:07 +03:00
10 lines
253 B
Rust
10 lines
253 B
Rust
#![feature(more_qualified_paths)]
|
|
macro_rules! show {
|
|
($ty:ty, $ex:expr) => {
|
|
match $ex {
|
|
<$ty>::A(_val) => println!("got a"), // formatting should not remove <$ty>::
|
|
<$ty>::B => println!("got b"),
|
|
}
|
|
};
|
|
}
|