rust/tests/ui/proc-macro/auxiliary/issue-38586.rs
2023-01-11 09:32:08 +00:00

12 lines
249 B
Rust

// force-host
// no-prefer-dynamic
#![crate_type = "proc-macro"]
extern crate proc_macro;
#[proc_macro_derive(A)]
pub fn derive_a(_: proc_macro::TokenStream) -> proc_macro::TokenStream {
"fn f() { println!(\"{}\", foo); }".parse().unwrap()
}