Skip to content

Commit 8705f3d

Browse files
Remove mention of .push_str(s) being faster
For the `.push_str(str.chars())` case the compiler will inline `push_str` and call `extend_from_slice` on the underlying vector, so this isn't actually faster.
1 parent e9f3911 commit 8705f3d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clippy_lints/src/methods.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -493,7 +493,7 @@ declare_lint! {
493493
/// **What it does:** Checks for the use of `.extend(s.chars())` where s is a
494494
/// `&str` or `String`.
495495
///
496-
/// **Why is this bad?** `.push_str(s)` is clearer and faster
496+
/// **Why is this bad?** `.push_str(s)` is clearer
497497
///
498498
/// **Known problems:** None.
499499
///

0 commit comments

Comments
 (0)