From 3f74f3b8459fdd451707511954a6ea3d128aabe3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20Tj=C3=A4der?= Date: Sun, 22 Jan 2023 00:35:03 +0100 Subject: [PATCH] Make clippy happy --- macros/src/codegen/idle.rs | 2 +- macros/src/codegen/init.rs | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/macros/src/codegen/idle.rs b/macros/src/codegen/idle.rs index 55b7e6230f..77a7f9feb2 100644 --- a/macros/src/codegen/idle.rs +++ b/macros/src/codegen/idle.rs @@ -59,7 +59,7 @@ pub fn codegen( analysis, extra, )); - let idle_doc = &format!(" User provided idle function"); + let idle_doc = " User provided idle function".to_string(); let attrs = &idle.attrs; let context = &idle.context; diff --git a/macros/src/codegen/init.rs b/macros/src/codegen/init.rs index e8a9c8b98c..34f86f2721 100644 --- a/macros/src/codegen/init.rs +++ b/macros/src/codegen/init.rs @@ -66,8 +66,8 @@ pub fn codegen(app: &App, analysis: &Analysis, extra: &Extra) -> CodegenResult { }) .collect(); - let shared_resources_doc = &format!(" RTIC shared resource struct"); - let local_resources_doc = &format!(" RTIC local resource struct"); + let shared_resources_doc = " RTIC shared resource struct".to_string(); + let local_resources_doc = " RTIC local resource struct".to_string(); root_init.push(quote! { #[doc = #shared_resources_doc] struct #shared { @@ -81,7 +81,7 @@ pub fn codegen(app: &App, analysis: &Analysis, extra: &Extra) -> CodegenResult { }); let user_init_return = quote! {#shared, #local, #name::Monotonics}; - let user_init_doc = &format!(" User provided init function"); + let user_init_doc = " User provided init function".to_string(); let user_init = quote!( #(#attrs)*