rust/tests/ui/underscore-imports/auxiliary/duplicate.rs
2023-01-11 09:32:08 +00:00

15 lines
297 B
Rust

// force-host
// no-prefer-dynamic
#![crate_type = "proc-macro"]
extern crate proc_macro;
use proc_macro::*;
#[proc_macro_attribute]
pub fn duplicate(_: TokenStream, input: TokenStream) -> TokenStream {
let clone = input.clone();
input.into_iter().chain(clone.into_iter()).collect()
}