mirror of
https://github.com/rust-lang/rust.git
synced 2025-04-28 02:57:37 +00:00
Update clippy_lints/src/use_retain.rs
Co-authored-by: llogiq <bogusandre@gmail.com>
This commit is contained in:
parent
5f2b8e67b3
commit
b20b8f10dd
@ -29,7 +29,7 @@ declare_clippy_lint! {
|
||||
/// ### What it does
|
||||
/// Checks for code to be replaced by `.retain()`.
|
||||
/// ### Why is this bad?
|
||||
/// `.retain()` is simpler.
|
||||
/// `.retain()` is simpler and avoids needless allocation.
|
||||
/// ### Example
|
||||
/// ```rust
|
||||
/// let mut vec = vec![0, 1, 2];
|
||||
|
Loading…
Reference in New Issue
Block a user