diff --git a/core/codegen/src/attribute/catch/mod.rs b/core/codegen/src/attribute/catch/mod.rs index bc22f15a..09528c71 100644 --- a/core/codegen/src/attribute/catch/mod.rs +++ b/core/codegen/src/attribute/catch/mod.rs @@ -20,6 +20,7 @@ pub fn _catch( let user_catcher_fn_name = &catch.function.sig.ident; let vis = &catch.function.vis; let status_code = Optional(catch.status.map(|s| s.code)); + let deprecated = catch.function.attrs.iter().find(|a| a.path().is_ident("deprecated")); // Determine the number of parameters that will be passed in. if catch.function.sig.inputs.len() > 2 { @@ -57,11 +58,12 @@ pub fn _catch( #user_catcher_fn #[doc(hidden)] - #[allow(non_camel_case_types)] + #[allow(nonstandard_style)] /// Rocket code generated proxy structure. - #vis struct #user_catcher_fn_name { } + #deprecated #vis struct #user_catcher_fn_name { } /// Rocket code generated proxy static conversion implementations. + #[allow(nonstandard_style, deprecated, clippy::style)] impl #user_catcher_fn_name { fn into_info(self) -> #_catcher::StaticInfo { fn monomorphized_function<'__r>( diff --git a/core/codegen/src/attribute/route/mod.rs b/core/codegen/src/attribute/route/mod.rs index 5de31306..8003dda4 100644 --- a/core/codegen/src/attribute/route/mod.rs +++ b/core/codegen/src/attribute/route/mod.rs @@ -343,7 +343,7 @@ fn codegen_route(route: Route) -> Result { #deprecated #vis struct #handler_fn_name { } /// Rocket code generated proxy static conversion implementations. - #[allow(nonstandard_style, deprecated)] + #[allow(nonstandard_style, deprecated, clippy::style)] impl #handler_fn_name { fn into_info(self) -> #_route::StaticInfo { fn monomorphized_function<'__r>( diff --git a/core/codegen/src/derive/uri_display.rs b/core/codegen/src/derive/uri_display.rs index 3afbfd11..1b5f2bf1 100644 --- a/core/codegen/src/derive/uri_display.rs +++ b/core/codegen/src/derive/uri_display.rs @@ -110,7 +110,6 @@ pub fn derive_uri_display_query(input: proc_macro::TokenStream) -> TokenStream { ts } -#[allow(non_snake_case)] pub fn derive_uri_display_path(input: proc_macro::TokenStream) -> TokenStream { let uri_display = DeriveGenerator::build_for(input.clone(), quote!(impl #P_URI_DISPLAY)) .support(Support::TupleStruct | Support::Type | Support::Lifetime)