rust/tests/ui/macros/macro-named-default.rs
2023-01-11 09:32:08 +00:00

19 lines
181 B
Rust

// run-pass
macro_rules! default {
($($x:tt)*) => { $($x)* }
}
default! {
struct A;
}
impl A {
default! {
fn foo(&self) {}
}
}
fn main() {
A.foo();
}