From 065975e0d73744bd28802b6b03c8f57263cf6a77 Mon Sep 17 00:00:00 2001 From: Dmitry Tantsur Date: Sat, 15 Apr 2023 19:48:56 +0200 Subject: [PATCH] chore(derive): fix clippy warnings (real 0.1.2 now) --- derive/src/lib.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/derive/src/lib.rs b/derive/src/lib.rs index aada2ce..be9594c 100644 --- a/derive/src/lib.rs +++ b/derive/src/lib.rs @@ -4,7 +4,6 @@ use convert_case::{Case, Casing}; use proc_macro::TokenStream; use proc_macro2::{Span, TokenStream as TS2}; use quote::{quote, ToTokens}; -use syn; #[proc_macro_derive( PaginatedResource, @@ -69,7 +68,7 @@ pub fn paginated_resource_macro_derive(input: TokenStream) -> TokenStream { .into() } -fn get_attr<'a>(attrs: &'a Vec, attr: &str) -> Option<&'a syn::Attribute> { +fn get_attr<'a>(attrs: &'a [syn::Attribute], attr: &str) -> Option<&'a syn::Attribute> { attrs.iter().find(|x| x.path.is_ident(attr)) }