From e1dd039ae376907ca9c47038b041c2d27074e50b Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Sat, 24 Jul 2021 12:14:15 +0100 Subject: [PATCH] config, wip macro Signed-off-by: Ian Jackson --- macros/macros.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/macros/macros.rs b/macros/macros.rs index 1585a63..13c727c 100644 --- a/macros/macros.rs +++ b/macros/macros.rs @@ -41,13 +41,9 @@ pub fn resolve(input: proc_macro::TokenStream) -> proc_macro::TokenStream { for attr in &field.attrs { if attr.tokens.is_empty() { let atspan = attr.path.segments.last().unwrap().ident.span(); + method = quote!{ #attr.path }; if &attr.path == &parse_quote!{ limited } { skl = quote_spanned!{atspan=> SKL::Limited }; - method = quote_spanned!{atspan=> limited }; - } else if &attr.path == &parse_quote!{ server } { - method = quote_spanned!{atspan=> server }; - } else if &attr.path == &parse_quote!{ client } { - method = quote_spanned!{atspan=> client }; } } else if &attr.path == &parse_quote!{ special } { let meta = match attr.parse_meta().unwrap() { -- 2.30.2