]> git.lizzy.rs Git - rust.git/commitdiff
Update clippy_lints/src/await_holding_invalid.rs
authorLily Mara <54288692+lilymara-onesignal@users.noreply.github.com>
Mon, 18 Apr 2022 17:32:11 +0000 (10:32 -0700)
committerGitHub <noreply@github.com>
Mon, 18 Apr 2022 17:32:11 +0000 (10:32 -0700)
Co-authored-by: llogiq <bogusandre@gmail.com>
clippy_lints/src/await_holding_invalid.rs

index 24c9f49d9f8bee79a1e170089f42e8f6cee774e4..be905f67ec8c4c5c7e4d7b07b06cfea78dc3937b 100644 (file)
@@ -269,7 +269,7 @@ fn emit_invalid_type(cx: &LateContext<'_>, span: Span, disallowed: &DisallowedTy
         &format!("`{type_name}` may not be held across an `await` point per `clippy.toml`",),
         |diag| {
             if let Some(reason) = reason {
-                diag.note(format!("{reason} (according to clippy.toml)"));
+                diag.note(reason.clone());
             }
         },
     );