Skip to content

Commit

Permalink
Automatic deploy to GitHub Pages: c24784e
Browse files Browse the repository at this point in the history
  • Loading branch information
GHA CI committed Nov 22, 2023
1 parent 9d7db4e commit d847a5a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion master/lints.json
Original file line number Diff line number Diff line change
Expand Up @@ -3420,7 +3420,7 @@
},
"group": "complexity",
"level": "warn",
"docs": "\n### What it does\n\nChecks for iterating a map (`HashMap` or `BTreeMap`) and\nignoring either the keys or values.\n\n### Why is this bad?\n\nReadability. There are `keys` and `values` methods that\ncan be used to express that we only need the keys or the values.\n\n### Example\n\n```rust\nlet map: HashMap<u32, u32> = HashMap::new();\nlet values = map.iter().map(|(_, value)| value).collect::<Vec<_>>();\n```\n\nUse instead:\n```rust\nlet map: HashMap<u32, u32> = HashMap::new();\nlet values = map.values().collect::<Vec<_>>();\n```",
"docs": "\n### What it does\n\nChecks for iterating a map (`HashMap` or `BTreeMap`) and\nignoring either the keys or values.\n\n### Why is this bad?\n\nReadability. There are `keys` and `values` methods that\ncan be used to express that we only need the keys or the values.\n\n### Example\n\n```rust\nlet map: HashMap<u32, u32> = HashMap::new();\nlet values = map.iter().map(|(_, value)| value).collect::<Vec<_>>();\n```\n\nUse instead:\n```rust\nlet map: HashMap<u32, u32> = HashMap::new();\nlet values = map.values().collect::<Vec<_>>();\n```\n\n### Configuration\nThis lint has the following configuration variables:\n\n- `msrv`: The minimum rust version that the project supports. Defaults to the `rust-version` field in `Cargo.toml`",
"version": "1.66.0",
"applicability": {
"is_multi_part_suggestion": false,
Expand Down

0 comments on commit d847a5a

Please sign in to comment.