]> git.lizzy.rs Git - rust.git/blob - tests/ui/proc-macro/derive-test.rs
add tests for 107090
[rust.git] / tests / ui / proc-macro / derive-test.rs
1 // run-pass
2 // no-prefer-dynamic
3 // compile-flags: --test
4
5 #![crate_type = "proc-macro"]
6
7 extern crate proc_macro;
8
9 use proc_macro::TokenStream;
10
11 // ```
12 // assert!(true);
13 // ```
14 #[proc_macro_derive(Foo)]
15 pub fn derive_foo(_input: TokenStream) -> TokenStream {
16     "".parse().unwrap()
17 }
18
19 #[test]
20 pub fn test_derive() {
21     assert!(true);
22 }