Skip to content

Commit 423f6ce

Browse files
committed
replace help message with try
1 parent 6974003 commit 423f6ce

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clippy_lints/src/strings.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@ impl<'tcx> LateLintPass<'tcx> for StrToString {
407407
STR_TO_STRING,
408408
expr.span,
409409
"`to_string()` called on a `&str`",
410-
"consider using `.to_owned()`",
410+
"try",
411411
format!("{snippet}.to_owned()"),
412412
applicability,
413413
);

0 commit comments

Comments
 (0)