Skip to content

Commit

Permalink
Fix file names of flat_map_identity test
Browse files Browse the repository at this point in the history
This commit fixes the file names of the `flat_map_identity` test.
Previously, their names were started with `unnecessary_flat_map` even
though the lint rule name is `flat_map_identity`. This inconsistency
happened probably because the rule name was changed during the
discussion in the PR where this rule was introduced.

ref: rust-lang#4231
  • Loading branch information
magurotuna committed Feb 3, 2021
1 parent c5f3f9d commit 6396b8f
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 2 deletions.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
error: called `flat_map(|x| x)` on an `Iterator`
--> $DIR/unnecessary_flat_map.rs:10:22
--> $DIR/flat_map_identity.rs:10:22
|
LL | let _ = iterator.flat_map(|x| x);
| ^^^^^^^^^^^^^^^ help: try: `flatten()`
|
= note: `-D clippy::flat-map-identity` implied by `-D warnings`

error: called `flat_map(std::convert::identity)` on an `Iterator`
--> $DIR/unnecessary_flat_map.rs:13:22
--> $DIR/flat_map_identity.rs:13:22
|
LL | let _ = iterator.flat_map(convert::identity);
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `flatten()`
Expand Down

0 comments on commit 6396b8f

Please sign in to comment.