dogfood test passed

This commit is contained in:
Samarth1696 2024-07-26 17:46:41 +05:30
parent 73039f654e
commit 6f01273d5d

View File

@ -87,15 +87,12 @@ fn suggest_non_zero_conversion(
target_non_zero_type: &str,
arg_snippet: &str,
) {
let suggestion = format!("{}::{}({})", target_non_zero_type, fn_name, arg_snippet);
let suggestion = format!("{target_non_zero_type}::{fn_name}({arg_snippet})");
span_lint_and_sugg(
cx,
NON_ZERO_SUGGESTIONS,
expr.span,
format!(
"Consider using `{}::{}()` for more efficient and type-safe conversion",
target_non_zero_type, fn_name
),
format!("Consider using `{target_non_zero_type}::{fn_name}()` for more efficient and type-safe conversion"),
"Replace with",
suggestion,
Applicability::MachineApplicable,