Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Clippy #84001

Merged
merged 144 commits into from
Apr 8, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
144 commits
Select commit Hold shift + click to select a range
9f6b5de
Merge commit '0e87918536b9833bbc6c683d1f9d51ee2bf03ef1' into clippyup
flip1995 Mar 25, 2021
3a4c0a7
Updated changelog for 1.52
xFrednet Mar 24, 2021
f41d68f
Auto merge of #6961 - xFrednet:changelog-1-52, r=flip1995
bors Mar 25, 2021
0ff68bb
Improve `redundant_slicing`
Jarcho Mar 26, 2021
63aca96
Auto merge of #6975 - Jarcho:redundant_slicing_fp, r=llogiq
bors Mar 26, 2021
caa49c8
Move absurd_extreme_comparisons to its own module
Y-Nak Mar 18, 2021
f231b59
Move invalid_upcast_comparisons to its own module
Y-Nak Mar 18, 2021
dad39b6
Move implicit_hasher to its own module
Y-Nak Mar 18, 2021
494bc8a
Fix FN that types lints don't work with const or static
Y-Nak Mar 19, 2021
bd1201a
Fix inconsistent test names
Y-Nak Mar 19, 2021
818f832
Merge type_complexity pass into types pass
Y-Nak Mar 20, 2021
1a1adad
Add MSRV option to unnested_or_patterns lint
flip1995 Mar 26, 2021
9ce9989
Improve doc on how to add MSRV to a lint
flip1995 Mar 26, 2021
5279b59
Fix trailing whitespaces in doc/adding_lints.md
flip1995 Mar 26, 2021
6f2a6fe
Auto merge of #6977 - flip1995:or_patterns_msrv, r=llogiq
bors Mar 26, 2021
5351bbf
Add missing lints to MSRV config doc
flip1995 Mar 26, 2021
0dddfbf
Use iter::zip in src/tools/clippy/
cuviper Mar 8, 2021
4e19d40
upper_case_acronyms: only lint enum variants if the enum is not public
matthiaskrgr Mar 26, 2021
ca7e955
upper_case_acronyms: add ui and ui-toml tests for private/public enums
matthiaskrgr Mar 26, 2021
ce4e668
format macro argument parsing fix
osa1 Mar 21, 2021
12985af
`len_without_is_empty` improvements
Jarcho Mar 26, 2021
dcee00d
Auto merge of #6980 - Jarcho:len_without_is_empty_sig, r=llogiq
bors Mar 27, 2021
8e56a2b
Auto merge of #6979 - flip1995:msrv_doc_fix, r=giraffate
bors Mar 27, 2021
febf34e
Move too_many_arguments to its own module
Y-Nak Mar 24, 2021
7c028de
Move too_many_lines to its own module
Y-Nak Mar 24, 2021
9782fc4
move not_unsafe_ptr_arg_deref to its own module
Y-Nak Mar 27, 2021
c379165
Move lints related to must_use to their own module
Y-Nak Mar 27, 2021
add3e50
Move result_unit_err to its own module
Y-Nak Mar 27, 2021
b094bb1
Rollup merge of #82917 - cuviper:iter-zip, r=m-ou-se
Dylan-DPC Mar 27, 2021
e006c77
redundant_pattern_matching: look inside Refs
matthiaskrgr Mar 27, 2021
a57a8c3
Remove (lots of) dead code
jyn514 Mar 16, 2021
879fa5c
Improve `expl_impl_clone_on_copy`
Jarcho Mar 28, 2021
4bcc552
Auto merge of #6991 - matthiaskrgr:5396, r=giraffate
bors Mar 28, 2021
c07103b
Auto merge of #6993 - Jarcho:expl_impl_clone, r=llogiq
bors Mar 28, 2021
1f95940
Fix inconsistent test name
Y-Nak Mar 29, 2021
31afdfc
missing_panics_doc: Ignore usage of debug_assert family
Y-Nak Mar 29, 2021
0e06b3c
Auto merge of #6996 - Y-Nak:missing_panics_doc, r=Manishearth
bors Mar 29, 2021
d265776
Improve `clone_on_copy`
Jarcho Mar 29, 2021
23508a1
Use uppercase for MSRV
giraffate Mar 29, 2021
a521445
Auto merge of #7003 - giraffate:use_uppercase_for_msrv, r=camsteffen
bors Mar 30, 2021
541c8b8
Improve documents in functions group
Y-Nak Mar 30, 2021
1ddeaa6
Auto merge of #6990 - Y-Nak:refactor-functions, r=giraffate
bors Mar 30, 2021
0552852
Auto merge of #7000 - Jarcho:clone_on_copy_fp, r=llogiq
bors Mar 30, 2021
6966c78
wrong_self_convention: fix FP inside trait impl for `to_*` method
mgacek8 Mar 29, 2021
fa689f8
Fix `manual_map` at the end of an if chain
Jarcho Mar 30, 2021
44bf60f
Auto merge of #7004 - Jarcho:manual_map_if_then_else, r=camsteffen
bors Mar 30, 2021
cc7f1da
Don't lint `manual_map` in const functions
Jarcho Mar 26, 2021
d121b34
Remove hir::CrateItem.
cjgillot Mar 30, 2021
7fcd155
Add non_octal_unix_permissions lint
ebobrow Mar 29, 2021
4be72b0
Auto merge of #7001 - ebobrow:non-octal-file-permissions, r=Manishearth
bors Mar 30, 2021
45164de
result_unit_err: Fix typo
Y-Nak Mar 31, 2021
0b76719
Auto merge of #7007 - Y-Nak:result_unit_err, r=giraffate
bors Mar 31, 2021
8abab55
Fix hidden variant suggestion on single variant
Mar 27, 2021
6ee1469
update lintcheck logs
matthiaskrgr Mar 31, 2021
225f7e0
lintcheck: warn if checking a program results in bad exit status
matthiaskrgr Mar 31, 2021
b438e30
Track bound vars
jackh726 Oct 6, 2020
2e33bf6
Auto merge of #6938 - Y-Nak:refactor-types, r=flip1995
bors Mar 31, 2021
3e42c35
Auto merge of #6981 - matthiaskrgr:6803_take_2, r=flip1995
bors Mar 31, 2021
5029dc8
New Lint: excessive_for_each
Y-Nak Feb 8, 2021
3095253
Fix codes that fails dogfood
Y-Nak Feb 9, 2021
54a0471
Change a category of excessive_for_each: Style -> Restriction
Y-Nak Feb 9, 2021
5bb0f16
Trigger the lint iff exposure's body is ExprKind::Block.
Y-Nak Feb 9, 2021
90cbbb2
Avoid to suggest using label
Y-Nak Feb 11, 2021
ccd7a60
Refactor: Remove duplicated codes from excessive_for_each
Y-Nak Feb 22, 2021
25d8b94
Add comments to clarify why RetCollector is needed
Y-Nak Feb 23, 2021
3843171
Improve the document of excessive_for_each
Y-Nak Feb 27, 2021
5543c34
Use ".." as default value of snippet in excessive_for_each
Y-Nak Feb 27, 2021
527fbbe
Refactor excessive_for_each
Y-Nak Mar 12, 2021
f2cc995
Remove method_calls
Y-Nak Mar 13, 2021
1109dc8
Fix codes that make dogfood fail
Y-Nak Mar 13, 2021
bf1e3f7
Skip needless_for_each if an input stmt is local
Y-Nak Mar 14, 2021
e61f978
Tweak a suggestion message of needless_for_each
Y-Nak Mar 15, 2021
56fbbf7
Suggest `flatten` instead of `is_some` -> `unwrap`
Nov 15, 2020
c1021b8
Auto merge of #6706 - Y-Nak:excessive-for-each, r=camsteffen
bors Mar 31, 2021
775ef47
Auto merge of #6342 - bbqbaron:issue-6061, r=flip1995
bors Mar 31, 2021
2108387
Destructure args in methods module
camsteffen Mar 11, 2021
487c2e8
Auto merge of #6913 - camsteffen:method-chain, r=flip1995
bors Mar 31, 2021
459bca8
Auto merge of #7008 - matthiaskrgr:ltchk, r=camsteffen
bors Mar 31, 2021
5f887d0
Add if_chain lints
camsteffen Mar 30, 2021
827d6aa
Eat dogfood
camsteffen Mar 30, 2021
aaba9b7
Fix `redundant_clone` fp where the cloned value is modified while the…
Jarcho Mar 31, 2021
8cf7d9b
Auto merge of #7010 - camsteffen:if-chain-lint, r=llogiq
bors Mar 31, 2021
6325fe1
clippy_utils: fix needless parenthesis output from sugg::Sugg::maybe_par
Y-Nak Apr 1, 2021
75d73e9
Auto merge of #6976 - Jarcho:manual_map_const, r=phansch
bors Apr 1, 2021
38b1fd0
Auto merge of #7002 - mgacek8:issue6983_wrong_self_convention_inside_…
bors Apr 1, 2021
92c4fc3
Auto merge of #7011 - Jarcho:redundant_clone_fp, r=flip1995
bors Apr 1, 2021
72eb60a
Auto merge of #7013 - Y-Nak:fix-needless-paren, r=flip1995
bors Apr 1, 2021
08a8ad3
Remove paths from bind_instead_of_map
camsteffen Apr 1, 2021
9f6f001
same_item_push: Don't trigger same_item_push if the vec is used in th…
Y-Nak Apr 2, 2021
1931db2
Auto merge of #6988 - mikerite:fix-6984, r=camsteffen
bors Apr 2, 2021
a064534
Refactor needless_collect
camsteffen Apr 2, 2021
4356a8f
Remove redundant emit()
camsteffen Apr 2, 2021
9ce2373
Auto merge of #7016 - camsteffen:bind-map-paths, r=Manishearth
bors Apr 2, 2021
33798bb
Improve needless_collect output
camsteffen Apr 2, 2021
86fb0e8
Auto merge of #7020 - camsteffen:needless-collect, r=Manishearth
bors Apr 2, 2021
2ca5368
fix clippy error
roxelo Mar 30, 2021
c726448
Remove attribute `#[link_args]`
petrochenkov Apr 3, 2021
7014340
Fix ICE
camsteffen Apr 2, 2021
5102c9c
Remove author requirement for `cargo_common_metadata`
daxpedda Apr 3, 2021
6f31ed6
Use DefIdMap and similar aliases
camsteffen Mar 31, 2021
984ab98
added core::panicking::assert_failed_inner as panicking
ABouttefeux Apr 4, 2021
2f81e4e
modification not working: fixing
ABouttefeux Apr 4, 2021
e25b106
Adding a dark theme to the clippy lint list
xFrednet Apr 2, 2021
6bb608c
Auto merge of #7030 - xFrednet:6877-clippy-going-dark, r=llogiq
bors Apr 4, 2021
da04e87
Quick fix to access the correct css files
xFrednet Apr 4, 2021
44e3ccb
Rollup merge of #83820 - petrochenkov:nolinkargs, r=nagisa
Dylan-DPC Apr 4, 2021
a15d987
Auto merge of #7021 - camsteffen:7012, r=giraffate
bors Apr 4, 2021
a00de90
Fix ICE in `missing_panics_doc`
Jarcho Apr 5, 2021
8e5dd4b
add test for missing_panic_doc on assert_eq/assert_ne
ABouttefeux Apr 5, 2021
e315437
Auto merge of #7031 - xFrednet:5234-quick-fix-dark-mode-themes, r=llogiq
bors Apr 5, 2021
8d221c5
Auto merge of #7027 - camsteffen:defidmap, r=phansch
bors Apr 5, 2021
81f9946
Auto merge of #7034 - Jarcho:missing_doc_ice, r=phansch
bors Apr 5, 2021
232e2b7
Added documentation to the multispan_sugg method
xFrednet Jan 5, 2021
d1df732
A new lint for shared code in if blocks
xFrednet Dec 11, 2020
469ff96
The shared_code_in_if_blocks lint only operats on entire if expr not …
xFrednet Jan 13, 2021
8efc6ac
Improved shared_code_in_if_blocks output readability and added tests
xFrednet Jan 16, 2021
b1d26e5
Improved shared_code_in_if_blocks message and added test stderrs
xFrednet Jan 16, 2021
65ed5a6
Updated code for dogfood
xFrednet Jan 16, 2021
c74e49e
Adapted the lint to use the new SpanlessEq
xFrednet Feb 23, 2021
617c65b
Moving shared_code_in_if_blocks to clippy::complexity and running lin…
xFrednet Feb 25, 2021
8c0b4d7
Only running shared_code_in_if_blocks only for if statements
xFrednet Feb 26, 2021
7c9e192
Test for empty blocks and update from master
xFrednet Mar 5, 2021
a6f54f5
Renaming the lint to branches_sharing_code and fixing typos
xFrednet Apr 1, 2021
1a45e43
Auto merge of #7026 - daxpedda:cargo-author, r=camsteffen
bors Apr 5, 2021
d91da40
Auto merge of #6463 - xFrednet:5234-shared-code-in-if-blocks, r=phansch
bors Apr 5, 2021
25c1ed3
Auto merge of #7029 - ABouttefeux:master, r=Manishearth
bors Apr 5, 2021
57406c9
Auto merge of #7018 - Y-Nak:same_item_push, r=Manishearth
bors Apr 5, 2021
8a50923
consider mutability on useless_vec suggestions
hmacias-avaya Apr 5, 2021
879bfec
Use AnonConst for asm! constants
Amanieu Apr 6, 2021
d2ba777
Auto merge of #7036 - horacimacias:master, r=giraffate
bors Apr 6, 2021
12fce55
Fix all occurences of `needless_borrow` internally
Jarcho Apr 2, 2021
6ae0835
Auto merge of #6931 - Jarcho:needless_borrow, r=phansch,flip1995
bors Apr 6, 2021
1efb551
Remove get_node_span
camsteffen Apr 1, 2021
79d3082
Remove paths::PATH_BUF
camsteffen Apr 1, 2021
a342de3
Soft deprecate match_path and match_qpath
camsteffen Apr 6, 2021
bbe1567
Auto merge of #7043 - camsteffen:dead-utils, r=flip1995
bors Apr 6, 2021
624e8aa
Auto merge of #7044 - camsteffen:match-path, r=Manishearth
bors Apr 6, 2021
47f0c15
Symbol optimizations
camsteffen Mar 24, 2021
db6ea84
Auto merge of #7046 - camsteffen:symbol-optimize, r=giraffate
bors Apr 7, 2021
cde58f7
Rollup merge of #83916 - Amanieu:asm_anonconst, r=petrochenkov
Dylan-DPC Apr 7, 2021
ffa2b7d
Merge remote-tracking branch 'upstream/master' into rustup
flip1995 Apr 8, 2021
61eafbb
Bump nightly version -> 2021-04-08
flip1995 Apr 8, 2021
b40ea20
Auto merge of #7051 - flip1995:rustup, r=flip1995
bors Apr 8, 2021
6b37cd3
Merge commit 'b40ea209e7f14c8193ddfc98143967b6a2f4f5c9' into clippyup
flip1995 Apr 8, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
146 changes: 143 additions & 3 deletions src/tools/clippy/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,146 @@ document.

## Unreleased / In Rust Nightly

[3e41797...master](https://github.com/rust-lang/rust-clippy/compare/3e41797...master)
[6ed6f1e...master](https://github.com/rust-lang/rust-clippy/compare/6ed6f1e...master)

## Rust 1.52

Current beta, release 2021-05-06

[3e41797...6ed6f1e](https://github.com/rust-lang/rust-clippy/compare/3e41797...6ed6f1e)

### New Lints

* [`from_str_radix_10`]
[#6717](https://github.com/rust-lang/rust-clippy/pull/6717)
* [`implicit_clone`]
[#6730](https://github.com/rust-lang/rust-clippy/pull/6730)
* [`semicolon_if_nothing_returned`]
[#6681](https://github.com/rust-lang/rust-clippy/pull/6681)
* [`manual_flatten`]
[#6646](https://github.com/rust-lang/rust-clippy/pull/6646)
* [`inconsistent_struct_constructor`]
[#6769](https://github.com/rust-lang/rust-clippy/pull/6769)
* [`iter_count`]
[#6791](https://github.com/rust-lang/rust-clippy/pull/6791)
* [`default_numeric_fallback`]
[#6662](https://github.com/rust-lang/rust-clippy/pull/6662)
* [`bytes_nth`]
[#6695](https://github.com/rust-lang/rust-clippy/pull/6695)
* [`filter_map_identity`]
[#6685](https://github.com/rust-lang/rust-clippy/pull/6685)
* [`manual_map`]
[#6573](https://github.com/rust-lang/rust-clippy/pull/6573)

### Moves and Deprecations

* Moved [`upper_case_acronyms`] to `pedantic`
[#6775](https://github.com/rust-lang/rust-clippy/pull/6775)
* Moved [`manual_map`] to `nursery`
[#6796](https://github.com/rust-lang/rust-clippy/pull/6796)
* Moved [`unnecessary_wraps`] to `pedantic`
[#6765](https://github.com/rust-lang/rust-clippy/pull/6765)
* Moved [`trivial_regex`] to `nursery`
[#6696](https://github.com/rust-lang/rust-clippy/pull/6696)
* Moved [`naive_bytecount`] to `pedantic`
[#6825](https://github.com/rust-lang/rust-clippy/pull/6825)
* Moved [`upper_case_acronyms`] to `style`
[#6788](https://github.com/rust-lang/rust-clippy/pull/6788)
* Moved [`manual_map`] to `style`
[#6801](https://github.com/rust-lang/rust-clippy/pull/6801)

### Enhancements

* [`disallowed_method`]: Now supports functions in addition to methods
[#6674](https://github.com/rust-lang/rust-clippy/pull/6674)
* [`upper_case_acronyms`]: Added a new configuration `upper-case-acronyms-aggressive` to
trigger the lint if there is more than one uppercase character next to each other
[#6788](https://github.com/rust-lang/rust-clippy/pull/6788)
* [`collapsible_match`]: Now supports block comparison with different value names
[#6754](https://github.com/rust-lang/rust-clippy/pull/6754)
* [`unnecessary_wraps`]: Will now suggest removing unnecessary wrapped return unit type, like `Option<()>`
[#6665](https://github.com/rust-lang/rust-clippy/pull/6665)
* Improved value usage detection in closures
[#6698](https://github.com/rust-lang/rust-clippy/pull/6698)

### False Positive Fixes

* [`use_self`]: No longer lints in macros
[#6833](https://github.com/rust-lang/rust-clippy/pull/6833)
* [`use_self`]: Fixed multiple false positives for: generics, associated types and derive implementations
[#6179](https://github.com/rust-lang/rust-clippy/pull/6179)
* [`missing_inline_in_public_items`]: No longer lints for procedural macros
[#6814](https://github.com/rust-lang/rust-clippy/pull/6814)
* [`inherent_to_string`]: No longer lints on functions with function generics
[#6771](https://github.com/rust-lang/rust-clippy/pull/6771)
* [`doc_markdown`]: Add `OpenDNS` to the default configuration as an allowed identifier
[#6783](https://github.com/rust-lang/rust-clippy/pull/6783)
* [`missing_panics_doc`]: No longer lints on [`unreachable!`](https://doc.rust-lang.org/std/macro.unreachable.html)
[#6700](https://github.com/rust-lang/rust-clippy/pull/6700)
* [`collapsible_if`]: No longer lints on if statements with attributes
[#6701](https://github.com/rust-lang/rust-clippy/pull/6701)
* [`match_same_arms`]: Only considers empty blocks as equal if the tokens contained are the same
[#6843](https://github.com/rust-lang/rust-clippy/pull/6843)
* [`redundant_closure`]: Now ignores macros
[#6871](https://github.com/rust-lang/rust-clippy/pull/6871)
* [`manual_map`]: Fixed false positives when control flow statements like `return`, `break` etc. are used
[#6801](https://github.com/rust-lang/rust-clippy/pull/6801)
* [`vec_init_then_push`]: Fixed false positives for loops and if statements
[#6697](https://github.com/rust-lang/rust-clippy/pull/6697)
* [`len_without_is_empty`]: Will now consider multiple impl blocks and `#[allow]` on
the `len` method as well as the type definition.
[#6853](https://github.com/rust-lang/rust-clippy/pull/6853)
* [`let_underscore_drop`]: Only lints on types which implement `Drop`
[#6682](https://github.com/rust-lang/rust-clippy/pull/6682)
* [`unit_arg`]: No longer lints on unit arguments when they come from a path expression.
[#6601](https://github.com/rust-lang/rust-clippy/pull/6601)
* [`cargo_common_metadata`]: No longer lints if
[`publish = false`](https://doc.rust-lang.org/cargo/reference/manifest.html#the-publish-field)
is defined in the manifest
[#6650](https://github.com/rust-lang/rust-clippy/pull/6650)

### Suggestion Fixes/Improvements

* [`collapsible_match`]: Fixed lint message capitalization
[#6766](https://github.com/rust-lang/rust-clippy/pull/6766)
* [`or_fun_call`]: Improved suggestions for `or_insert(vec![])`
[#6790](https://github.com/rust-lang/rust-clippy/pull/6790)
* [`manual_map`]: No longer expands macros in the suggestions
[#6801](https://github.com/rust-lang/rust-clippy/pull/6801)
* Aligned Clippy's lint messages with the rustc dev guide
[#6787](https://github.com/rust-lang/rust-clippy/pull/6787)

### ICE Fixes

* [`zero_sized_map_values`]
[#6866](https://github.com/rust-lang/rust-clippy/pull/6866)

### Documentation Improvements

* [`useless_format`]: Improved the documentation example
[#6854](https://github.com/rust-lang/rust-clippy/pull/6854)
* Clippy's [`README.md`]: Includes a new subsection on running Clippy as a rustc wrapper
[#6782](https://github.com/rust-lang/rust-clippy/pull/6782)

### Others
* Running `cargo clippy` after `cargo check` now works as expected
(`cargo clippy` and `cargo check` no longer shares the same build cache)
[#6687](https://github.com/rust-lang/rust-clippy/pull/6687)
* Cargo now re-runs Clippy if arguments after `--` provided to `cargo clippy` are changed.
[#6834](https://github.com/rust-lang/rust-clippy/pull/6834)
* Extracted Clippy's `utils` module into the new `clippy_utils` crate
[#6756](https://github.com/rust-lang/rust-clippy/pull/6756)
* Clippy lintcheck tool improvements
[#6800](https://github.com/rust-lang/rust-clippy/pull/6800)
[#6735](https://github.com/rust-lang/rust-clippy/pull/6735)
[#6764](https://github.com/rust-lang/rust-clippy/pull/6764)
[#6708](https://github.com/rust-lang/rust-clippy/pull/6708)
[#6780](https://github.com/rust-lang/rust-clippy/pull/6780)
[#6686](https://github.com/rust-lang/rust-clippy/pull/6686)

## Rust 1.51

Current beta, release 2021-03-25
Current stable, released 2021-03-25

[4911ab1...3e41797](https://github.com/rust-lang/rust-clippy/compare/4911ab1...3e41797)

Expand Down Expand Up @@ -125,7 +260,7 @@ Current beta, release 2021-03-25

## Rust 1.50

Current stable, released 2021-02-11
Released 2021-02-11

[b20d4c1...4bd77a1](https://github.com/rust-lang/rust-clippy/compare/b20d4c1...4bd77a1)

Expand Down Expand Up @@ -1970,6 +2105,7 @@ Released 2018-09-13
[configuration file]: ./rust-clippy#configuration
[pull3665]: https://github.com/rust-lang/rust-clippy/pull/3665
[adding_lints]: https://github.com/rust-lang/rust-clippy/blob/master/doc/adding_lints.md
[`README.md`]: https://github.com/rust-lang/rust-clippy/blob/master/README.md

<!-- lint disable no-unused-definitions -->
<!-- begin autogenerated links to lint list -->
Expand All @@ -1993,6 +2129,7 @@ Released 2018-09-13
[`borrowed_box`]: https://rust-lang.github.io/rust-clippy/master/index.html#borrowed_box
[`box_vec`]: https://rust-lang.github.io/rust-clippy/master/index.html#box_vec
[`boxed_local`]: https://rust-lang.github.io/rust-clippy/master/index.html#boxed_local
[`branches_sharing_code`]: https://rust-lang.github.io/rust-clippy/master/index.html#branches_sharing_code
[`builtin_type_shadow`]: https://rust-lang.github.io/rust-clippy/master/index.html#builtin_type_shadow
[`bytes_nth`]: https://rust-lang.github.io/rust-clippy/master/index.html#bytes_nth
[`cargo_common_metadata`]: https://rust-lang.github.io/rust-clippy/master/index.html#cargo_common_metadata
Expand Down Expand Up @@ -2233,6 +2370,7 @@ Released 2018-09-13
[`needless_collect`]: https://rust-lang.github.io/rust-clippy/master/index.html#needless_collect
[`needless_continue`]: https://rust-lang.github.io/rust-clippy/master/index.html#needless_continue
[`needless_doctest_main`]: https://rust-lang.github.io/rust-clippy/master/index.html#needless_doctest_main
[`needless_for_each`]: https://rust-lang.github.io/rust-clippy/master/index.html#needless_for_each
[`needless_lifetimes`]: https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
[`needless_pass_by_value`]: https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_value
[`needless_question_mark`]: https://rust-lang.github.io/rust-clippy/master/index.html#needless_question_mark
Expand All @@ -2246,13 +2384,15 @@ Released 2018-09-13
[`new_without_default`]: https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default
[`no_effect`]: https://rust-lang.github.io/rust-clippy/master/index.html#no_effect
[`non_ascii_literal`]: https://rust-lang.github.io/rust-clippy/master/index.html#non_ascii_literal
[`non_octal_unix_permissions`]: https://rust-lang.github.io/rust-clippy/master/index.html#non_octal_unix_permissions
[`nonminimal_bool`]: https://rust-lang.github.io/rust-clippy/master/index.html#nonminimal_bool
[`nonsensical_open_options`]: https://rust-lang.github.io/rust-clippy/master/index.html#nonsensical_open_options
[`not_unsafe_ptr_arg_deref`]: https://rust-lang.github.io/rust-clippy/master/index.html#not_unsafe_ptr_arg_deref
[`ok_expect`]: https://rust-lang.github.io/rust-clippy/master/index.html#ok_expect
[`op_ref`]: https://rust-lang.github.io/rust-clippy/master/index.html#op_ref
[`option_as_ref_deref`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_as_ref_deref
[`option_env_unwrap`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_env_unwrap
[`option_filter_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_filter_map
[`option_if_let_else`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else
[`option_map_or_none`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_map_or_none
[`option_map_unit_fn`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_map_unit_fn
Expand Down
2 changes: 1 addition & 1 deletion src/tools/clippy/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

A collection of lints to catch common mistakes and improve your [Rust](https://github.com/rust-lang/rust) code.

[There are over 400 lints included in this crate!](https://rust-lang.github.io/rust-clippy/master/index.html)
[There are over 450 lints included in this crate!](https://rust-lang.github.io/rust-clippy/master/index.html)

Lints are divided into categories, each with a default [lint level](https://doc.rust-lang.org/rustc/lints/levels.html).
You can choose how much Clippy is supposed to ~~annoy~~ help you by changing the lint level by category.
Expand Down
2 changes: 1 addition & 1 deletion src/tools/clippy/clippy_dev/src/fmt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ pub fn run(check: bool, verbose: bool) {
continue;
}

success &= rustfmt(context, &path)?;
success &= rustfmt(context, path)?;
}

Ok(success)
Expand Down
16 changes: 8 additions & 8 deletions src/tools/clippy/clippy_dev/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ impl Lint {
#[must_use]
pub fn gen_lint_group_list<'a>(lints: impl Iterator<Item = &'a Lint>) -> Vec<String> {
lints
.map(|l| format!(" LintId::of(&{}::{}),", l.module, l.name.to_uppercase()))
.map(|l| format!(" LintId::of({}::{}),", l.module, l.name.to_uppercase()))
.sorted()
.collect::<Vec<String>>()
}
Expand Down Expand Up @@ -154,17 +154,17 @@ pub fn gen_register_lint_list<'a>(
let header = " store.register_lints(&[".to_string();
let footer = " ]);".to_string();
let internal_lints = internal_lints
.sorted_by_key(|l| format!(" &{}::{},", l.module, l.name.to_uppercase()))
.sorted_by_key(|l| format!(" {}::{},", l.module, l.name.to_uppercase()))
.map(|l| {
format!(
" #[cfg(feature = \"internal-lints\")]\n &{}::{},",
" #[cfg(feature = \"internal-lints\")]\n {}::{},",
l.module,
l.name.to_uppercase()
)
});
let other_lints = usable_lints
.sorted_by_key(|l| format!(" &{}::{},", l.module, l.name.to_uppercase()))
.map(|l| format!(" &{}::{},", l.module, l.name.to_uppercase()))
.sorted_by_key(|l| format!(" {}::{},", l.module, l.name.to_uppercase()))
.map(|l| format!(" {}::{},", l.module, l.name.to_uppercase()))
.sorted();
let mut lint_list = vec![header];
lint_list.extend(internal_lints);
Expand Down Expand Up @@ -550,9 +550,9 @@ fn test_gen_lint_group_list() {
Lint::new("internal", "internal_style", "abc", None, "module_name"),
];
let expected = vec![
" LintId::of(&module_name::ABC),".to_string(),
" LintId::of(&module_name::INTERNAL),".to_string(),
" LintId::of(&module_name::SHOULD_ASSERT_EQ),".to_string(),
" LintId::of(module_name::ABC),".to_string(),
" LintId::of(module_name::INTERNAL),".to_string(),
" LintId::of(module_name::SHOULD_ASSERT_EQ),".to_string(),
];
assert_eq!(expected, gen_lint_group_list(lints.iter()));
}
Loading