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 #104688

Merged
merged 267 commits into from
Nov 22, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
267 commits
Select commit Hold shift + click to select a range
46cf1ea
Auto merge of #103344 - Dylan-DPC:rollup-d1rpfvx, r=Dylan-DPC
bors Oct 21, 2022
6551754
[`unwrap_used`], [`expect_used`] do not lint in `test` cfg
kraktus Oct 21, 2022
2ed4049
Introduce subst_iter and subst_iter_copied on EarlyBinder
compiler-errors Oct 16, 2022
a0c82d2
Explicitly mention [cfg(test)]
kraktus Oct 22, 2022
cd0bb7d
Merge commit '4f142aa1058f14f153f8bfd2d82f04ddb9982388' into clippyup
flip1995 Oct 23, 2022
a8a8fd7
Auto merge of #9686 - kraktus:unwrap_in_test_cfg, r=flip1995
bors Oct 23, 2022
8e03f91
Auto merge of #9654 - alex-semenyuk:enable_test, r=Alexendoo
bors Oct 23, 2022
ff89336
Mark `let_underscore_drop` as uplifted
Alexendoo Oct 23, 2022
9306540
Remove overlap between rustc and clippy `let_underscore_lock` lint
Alexendoo Oct 23, 2022
3f4287c
Auto merge of #9697 - Alexendoo:let-underscore-uplift, r=flip1995
bors Oct 23, 2022
a41cb7a
fix: support `map_or` for `or_fun_call` lint
koka831 Oct 22, 2022
b97d29a
Auto merge of #9689 - koka831:fix/or_fun_call_map_or, r=flip1995
bors Oct 23, 2022
fe57ab7
Auto merge of #9630 - CatDevz:fix-aawr-lint, r=flip1995
bors Oct 23, 2022
628a79d
Auto merge of #9368 - nahuakang:improve-equatable-if-let, r=flip1995
bors Oct 23, 2022
b083a39
add `boxed_void` lint
roynrishingha Oct 22, 2022
191c983
Auto merge of #9690 - royrustdev:boxed_void, r=flip1995
bors Oct 23, 2022
a201518
Generate lint categories and explanations with `declare_clippy_lint`
Alexendoo Oct 23, 2022
8134566
Remove `src/docs`
Alexendoo Oct 23, 2022
5b09d4e
Auto merge of #9541 - Alexendoo:declare-proc-macro, r=flip1995
bors Oct 23, 2022
e49cde7
Update `from_raw_with_void_ptr` to support types other than `Box`
andreubotella Oct 23, 2022
8d6ce31
Add new lint `rewind_instead_of_seek_to_start`
dblnz Oct 16, 2022
b48a466
Add msrv check for `rewind_instead_of_seek_to_start` lint
dblnz Oct 21, 2022
e86e810
[`use_self`] fix FP when trait impl defined in macro
kraktus Oct 24, 2022
b9b9d6a
Change lint name to `seek_to_start_instead_of_rewind`
dblnz Oct 24, 2022
0e360d0
Move needless_collect to nursery
sophiajt Oct 24, 2022
4f3fb00
Update the corresponding test and bless tests
sophiajt Oct 24, 2022
beae0d2
Address some comments
Oct 24, 2022
f827be9
Add lint to tell about let else pattern
est31 Feb 13, 2022
2e01e6b
Also support linting for match
est31 Feb 16, 2022
c5a7696
Support tuples
est31 Feb 18, 2022
5da7a17
Don't suggest let else in match if the else arm explicitly mentions n…
est31 Feb 19, 2022
173a8e0
Replace from_different_macros with equivalent and simpler check
est31 Oct 6, 2022
9bd70db
Make the match checking configurable
est31 Oct 8, 2022
a1db931
Make an attempt of creating suggestions
est31 Oct 10, 2022
01e651f
Don't lint if the let is already a let-else
oxalica Oct 10, 2022
748169d
Don't fire the lint if there is a type annotation
est31 Oct 10, 2022
96ea5b2
Fix dogfooding
est31 Oct 11, 2022
dcde480
Also consider match guards for divergence check
est31 Oct 16, 2022
b698a15
Auto merge of #8437 - est31:let_else_lint, r=flip1995
bors Oct 24, 2022
48edc83
Add more normalization and tests
Oct 24, 2022
eba36e6
make arc-likes for `mutable-key` configurable
llogiq Oct 20, 2022
039af9c
Auto merge of #9667 - dorublanzeanu:master, r=giraffate
bors Oct 25, 2022
6f16596
Auto merge of #9704 - kraktus:fix_use_self, r=giraffate
bors Oct 25, 2022
70dff63
chore: remove remove-unnecessary-files
koka831 Oct 25, 2022
6efb3a2
feat: add new lint `seek_from_current`
koka831 Oct 25, 2022
de87e83
Auto merge of #9700 - andreubotella:from-raw-with-void-non-box, r=fli…
bors Oct 25, 2022
df67ebb
Auto merge of #9709 - koka831:chore/remove-unnecessary-files, r=flip1995
bors Oct 25, 2022
9a42501
Auto merge of #9692 - llogiq:mutable-key-more-arcs, r=Alexendoo
bors Oct 25, 2022
bd83690
Track `clippy.toml` and `Cargo.toml` in `file_depinfo`
Alexendoo Oct 25, 2022
5e29870
Auto merge of #9707 - Alexendoo:file-depinfo, r=flip1995
bors Oct 25, 2022
5b336fd
Auto merge of #103392 - RalfJung:miri, r=oli-obk
bors Oct 25, 2022
22d435b
Remove `lib.register_*` and `src/docs*` in `cargo dev update_lints`
Alexendoo Oct 25, 2022
634987b
Auto merge of #9712 - Alexendoo:old-generated-files, r=flip1995
bors Oct 25, 2022
d80b184
Remove note mentioning configuration changes need cargo clean
Alexendoo Oct 25, 2022
32ded57
Just lint changes
blyxyas Oct 21, 2022
64308d6
Lints updated
blyxyas Oct 25, 2022
7182a6b
Auto merge of #9681 - koka831:feat/add-seek-from-current-lint, r=gira…
bors Oct 26, 2022
98250af
`question_mark` don't lint on `if let Err` with else
ebobrow Oct 26, 2022
770362a
fix dupe word typos
Rageking8 Oct 26, 2022
ec9edbc
Auto merge of #9723 - Rageking8:fix-dupe-word-typos, r=llogiq
bors Oct 26, 2022
70187c7
Auto merge of #9717 - Alexendoo:readme-note, r=flip1995
bors Oct 26, 2022
4b1cebb
Adjust normalization
Oct 26, 2022
45c000b
privacy: Rename "accessibility levels" to "effective visibilities"
petrochenkov Sep 22, 2022
1909a6a
[`use_self`] fix suggestion when full path to struct was given
kraktus Oct 26, 2022
83771c5
Fix `needless_borrow` false positive
smoelius Oct 26, 2022
40af5be
Auto merge of #9674 - smoelius:needless-borrow-fp, r=Jarcho
bors Oct 27, 2022
14a34c2
move `UNINLINED_FORMAT_ARGS` to pedantic
dswij Oct 27, 2022
710999d
Auto merge of #9728 - dswij:uninlined-fargs-pedantic, r=flip1995
bors Oct 27, 2022
f5d225d
Auto merge of #9722 - ebobrow:question-mark, r=Manishearth
bors Oct 27, 2022
471d855
Update tooling
WaffleLapkin Oct 27, 2022
e27e13c
Ensure new_ret_no_self is not fired if `impl Trait<Self>` is returned.
nbdd0121 Oct 27, 2022
92a119b
Add unit tests for issue 7344
nbdd0121 Oct 27, 2022
151395d
Update clippy_lints/src/suspicious_xor_used_as_pow.rs
blyxyas Oct 27, 2022
6e6a803
Move clippy::uninlined_format_args back to pedantic
flip1995 Oct 27, 2022
4326814
Auto merge of #9726 - kraktus:fix_use_self, r=Alexendoo
bors Oct 27, 2022
33137dd
Auto merge of #9733 - nbdd0121:master, r=dswij
bors Oct 28, 2022
678e675
Retain ParamEnv constness when running deferred cast checks
fee1-dead Oct 28, 2022
fa6850d
[`bool_to_int_with_if`] do not lint in const context
kraktus Oct 28, 2022
c42626f
Fix #9710
smoelius Oct 25, 2022
7e68c71
fix the `string-extend-chars` suggestion on slice
llogiq Oct 28, 2022
e9216d8
Improve `needless_lifetimes`
smoelius Oct 28, 2022
10b7fab
Fix adjacent code
smoelius Oct 28, 2022
1bfbd3d
Fix badge
alex-semenyuk Oct 24, 2022
e19fe89
fix `undocumented-unsafe-blocks` false positive
llogiq Oct 14, 2022
71ddf81
Auto merge of #9741 - llogiq:fix-string-extend-chars-slice-ref, r=Man…
bors Oct 28, 2022
0ab512c
Auto merge of #9711 - smoelius:issue-9710, r=Jarcho
bors Oct 29, 2022
fdaa425
Auto merge of #9648 - llogiq:fix-undocumented-unsafe-blocks, r=Jarcho
bors Oct 29, 2022
26eeeee
Auto merge of #102233 - petrochenkov:effvis, r=jackh726
bors Oct 29, 2022
efca32e
Rename some `OwnerId` fields.
nnethercote Oct 27, 2022
8e19251
Auto merge of #9738 - kraktus:bool_to_int_with_if, r=xFrednet
bors Oct 29, 2022
ad5dfcd
Fix `bool_to_int_with_if` false positive with `if let`
Alexendoo Oct 29, 2022
dff041f
Rollup merge of #103625 - WaffleLapkin:no_tyctxt_dogs_allowed, r=comp…
GuillaumeGomez Oct 29, 2022
cca9938
Auto merge of #9714 - Alexendoo:bool-to-int-if-let, r=xFrednet
bors Oct 29, 2022
00cf07b
[`option_if_let_else`] do not lint if any arm has guard
kraktus Oct 29, 2022
16566e9
Use LanguageItems::require less
camsteffen Oct 26, 2022
2c44398
Adress review comments
smoelius Oct 30, 2022
bde33a3
Update CONTRIBUTING.md
smoelius Oct 30, 2022
b16a534
Warn when clippy::restriction is enabled via the command line
Alexendoo Oct 30, 2022
10e07cc
Auto merge of #9755 - Alexendoo:restriction-cli-warn, r=Manishearth
bors Oct 30, 2022
00610b3
Auto merge of #9747 - kraktus:option_if_let_else, r=Manishearth
bors Oct 30, 2022
60d1718
Auto merge of #9734 - alex-semenyuk:badge, r=giraffate
bors Oct 31, 2022
37d338c
Auto merge of #9506 - blyxyas:master, r=giraffate
bors Oct 31, 2022
6dcade0
Implement let_underscore_future
SquareMan Oct 31, 2022
1f93045
update_lints
SquareMan Oct 31, 2022
9e7996b
Update lint versions for 1.65
xFrednet Oct 31, 2022
c0d9285
Change two `<=` to `==` for clarity
smoelius Nov 1, 2022
7600535
Auto merge of #9743 - smoelius:improve-needless-lifetimes, r=Alexendoo
bors Nov 1, 2022
30e662d
Changelog for Rust 1.65 :traffic_light:
xFrednet Oct 31, 2022
9f2852f
Auto merge of #103217 - mejrs:track, r=eholk
bors Nov 1, 2022
9f618b1
Un-ingnore code snippets
SquareMan Nov 1, 2022
139f2a3
Surround let with backticks
SquareMan Nov 1, 2022
b7d9af2
Fix examples
SquareMan Nov 2, 2022
d35b7de
shrink `missing_{safety,errors,panics}_doc` spans
Nov 2, 2022
517605e
Fix ICE in `redundant_allocation`
Alexendoo Nov 2, 2022
647644b
Auto merge of #9772 - lukas-code:doc-spans, r=Manishearth
bors Nov 2, 2022
8d7f638
Auto merge of #9773 - Alexendoo:ice-9746, r=Manishearth
bors Nov 2, 2022
6b4e7dd
Auto merge of #9761 - xFrednet:changelog-1-65, r=giraffate,xFrednet
bors Nov 3, 2022
05006e5
fix turbofish in suggest message
koka831 Nov 3, 2022
704e00c
Auto merge of #9779 - koka831:fix/unnecessary-join-message, r=Jarcho
bors Nov 3, 2022
50f63a0
Address issues 9739 and 9782
smoelius Nov 4, 2022
188e8e9
improve `filesearch::get_or_default_sysroot` r=ozkanonur
onur-ozkan Oct 28, 2022
ddcfff6
Add allow-print-in-tests config
trevarj Nov 4, 2022
f86c35c
Update lint `suspicious_to_owned`
bebecue Nov 4, 2022
4cb9681
Auto merge of #9753 - smoelius:changelog, r=xFrednet
bors Nov 4, 2022
1e1ac2b
Return multiple resolutions from `def_path_res`
Alexendoo Nov 4, 2022
93dab8f
More backticks
SquareMan Nov 5, 2022
398f946
bless
SquareMan Nov 5, 2022
7c5b188
Bless all let_underscore tests
SquareMan Nov 5, 2022
40dca3d
Rollup merge of #103660 - ozkanonur:master, r=jyn514
Dylan-DPC Nov 5, 2022
9e0de8c
Auto merge of #9799 - bebecue:patch-1, r=dswij
bors Nov 5, 2022
e547411
Auto merge of #9797 - trevarj:print-config, r=xFrednet
bors Nov 5, 2022
fa694ec
Update CoC to rust-lang/rust's
Alexendoo Nov 5, 2022
d15e5e6
Auto merge of #9760 - SquareMan:let_underscore_future, r=llogiq
bors Nov 5, 2022
e4540ad
feat: implement manual_is_ascii_check lint
koka831 Oct 24, 2022
927f7da
Auto merge of #9804 - Alexendoo:coc, r=flip1995
bors Nov 7, 2022
213003b
Auto merge of #9705 - jntrnr:disable_needless_collect, r=Manishearth
bors Nov 7, 2022
b0dcb86
Move `needless_collect` into the `methods` lint pass
Jarcho Apr 22, 2022
586bd3f
refactor to avoid potential ICE
kraktus Oct 23, 2022
9c69e93
Rewrite `ExcessiveBools` to be a `LateLintPass` lint
kraktus Oct 28, 2022
e8c2c3d
refactor `has_repr_attr`
kraktus Oct 28, 2022
d9b940e
dogfood
kraktus Oct 23, 2022
9e1c7fe
`excessive_bools`, do not lint in trait impls
kraktus Oct 29, 2022
13b737d
[`fn_params_excessive_bools`] whitelist in signle function in test
kraktus Oct 29, 2022
8bfc8bc
Lint `needless_collect` on non-std collection types
Jarcho Apr 20, 2022
5b1e445
Don't lint `explicit_auto_deref` when the target type is a projection…
Jarcho Nov 7, 2022
3d4b73c
[`excessive_bools`] lint trait functions even without bodies
kraktus Nov 7, 2022
5857a01
Auto merge of #8744 - Jarcho:needless_collect_fp, r=llogiq
bors Nov 7, 2022
80e5856
`result_large_err` show largest variants in err msg
ebobrow Oct 16, 2022
4abe815
Auto merge of #9765 - koka831:feat/manual_is_ascii_check, r=xFrednet
bors Nov 8, 2022
7001085
Update lint example for `collapsible_str_replace`
mgrachev Nov 8, 2022
43a6d0b
Fixed Typo
rs017991 Nov 8, 2022
4e31877
Auto merge of #9818 - rs017991:patch-1, r=Jarcho
bors Nov 8, 2022
b9ca319
Auto merge of #9791 - smoelius:issues-9739-9782, r=Jarcho
bors Nov 8, 2022
c4fbe54
Auto merge of #9817 - mgrachev:patch-1, r=Manishearth
bors Nov 8, 2022
84c3a95
bless clippy
chenyukang Nov 9, 2022
432baf7
Auto merge of #9813 - Jarcho:issue_9811, r=xFrednet
bors Nov 9, 2022
146bd1e
Add `unnecessary_safety_doc` lint
Veykril Nov 9, 2022
708c2d9
feat: add and implement unchecked_duration_subtraction lint
nfejzic Oct 1, 2022
3b4e42b
test: add tests for 'unchecked_duration_subtraction' lint
nfejzic Oct 1, 2022
b280dbe
docs: add docs for `unchecked_duration_subtraction` lint
nfejzic Oct 1, 2022
b485832
style: remove `dbg!` call
nfejzic Oct 1, 2022
2f2eb2e
refactor: lint man. instant elapsed and unch. dur. subtr. in single pass
nfejzic Nov 7, 2022
a566eb3
docs: update docs for unchecked duration subtr. lint
nfejzic Nov 7, 2022
80e3553
refactor: improve code re-use in InstantSubtraction lint pass
nfejzic Nov 7, 2022
4bd6d0b
test: update tests for manual_instant_elapsed lint
nfejzic Nov 7, 2022
852d802
style: inline variables in `format!`
nfejzic Nov 7, 2022
62ab4fb
fix: add rust-fix annotation to unckd. duration subtr. lint test
nfejzic Nov 8, 2022
862ac29
fix: remove (redundant) semicolon in lint suggestion
nfejzic Nov 8, 2022
36eac0c
fix: update lints
nfejzic Nov 10, 2022
2bc04bd
fix: cognitive_complexity for async fn
koka831 Nov 10, 2022
4f1698d
Auto merge of #9828 - koka831:fix/9300, r=Alexendoo
bors Nov 10, 2022
3790aa3
Make `bool_to_int_with_if` a pedantic lint
hrxi Nov 10, 2022
3c0ad8a
Auto merge of #9830 - hrxi:pr_bool_to_int_with_if, r=Manishearth
bors Nov 10, 2022
cad0d3d
Auto merge of #9662 - ebobrow:result-large-err, r=dswij
bors Nov 11, 2022
7ddd321
Introduce `ExprKind::IncludedBytes`
clubby789 Oct 31, 2022
39398e1
fix: use HasPlaceholders
koka831 Nov 12, 2022
93edc12
Avoid lint to unsized mutable reference
koka831 Nov 12, 2022
755fe4d
Auto merge of #9834 - koka831:refac/manual-is-ascii-check, r=xFrednet
bors Nov 12, 2022
34c4520
Fix is_async_fn to check FnKind::Method
koka831 Nov 12, 2022
9899861
fix never_loop false positive
kartva Nov 12, 2022
bb326e7
Auto merge of #9836 - koka831:patch-9300, r=Alexendoo
bors Nov 12, 2022
9f283c9
Auto merge of #9835 - koka831:fix/9035, r=Alexendoo
bors Nov 12, 2022
243661b
Make it clear that `or_fun_call` can be a false-positive
hrxi Nov 12, 2022
a815140
Auto merge of #9698 - kraktus:xc_bool, r=xFrednet
bors Nov 13, 2022
e6ef478
Store a LocalDefId in hir::Variant & hir::Field.
cjgillot Nov 6, 2022
6ba3a00
Auto merge of #9822 - Veykril:unnecessary-safety-doc, r=Jarcho
bors Nov 13, 2022
493b788
Auto merge of #9829 - hrxi:pr_or_fun_call, r=llogiq
bors Nov 13, 2022
a599527
Auto merge of #9837 - DesmondWillowbrook:never_loop, r=dswij
bors Nov 13, 2022
8a2d0f2
Fix clippy and rustdoc
WaffleLapkin Nov 13, 2022
b8357ff
fix `vec-box-size-threshold` off-by-one error
Nov 14, 2022
3c7f74d
Auto merge of #9848 - lukas-code:vec-box, r=Jarcho
bors Nov 14, 2022
3f89ab0
chore: update lint version of MANUAL_INSTAN_ELAPSED to 1.65
nfejzic Nov 14, 2022
912dc91
docs: update unchecked duration subtraction lint doc
nfejzic Nov 14, 2022
72ab91d
fix: add extract_msrv_attr call to instan_subtraction lint pass
nfejzic Nov 14, 2022
0dd6ce0
docs: import Instant and Duration in doctests
nfejzic Nov 14, 2022
7c4611c
Allow return types for closures with lifetime binder
koka831 Nov 15, 2022
93ac0f5
Keep `ref` on `infallible_destructuring_match` suggestion
pheki Nov 15, 2022
5b0d727
Auto merge of #9570 - nfejzic:lint-unchecked-duration-subtraction, r=…
bors Nov 15, 2022
38e0590
Auto merge of #9849 - koka831:fix/9748, r=Manishearth
bors Nov 15, 2022
f75fc85
Extend `needless_borrowed_reference` to structs and tuples, ignore _
Alexendoo Nov 15, 2022
f2d83ed
Use `token::Lit` in `ast::ExprKind::Lit`.
nnethercote Oct 10, 2022
9f3b6e9
don't emit AlwaysBreaks if it targets a block
kartva Nov 16, 2022
036a010
update tests
kartva Nov 16, 2022
bc3cd34
fix clippy suggestions
kartva Nov 16, 2022
2bf87f3
cleanup and dedupe CTFE and Miri error reporting
RalfJung Nov 15, 2022
e5352c7
Convert predicates into Predicate in the Obligation constructor
oli-obk Nov 9, 2022
3f015a3
Avoid generating files via doctest
koka831 Nov 16, 2022
dac600e
Auto merge of #9859 - koka831:no-run-side-effect, r=Manishearth
bors Nov 16, 2022
cbd6159
Auto merge of #102944 - nnethercote:ast-Lit-third-time-lucky, r=petro…
bors Nov 16, 2022
333b92c
Box `ExprKind::{Closure,MethodCall}`, and `QSelf` in expressions, typ…
nnethercote Sep 8, 2022
11d632f
Auto merge of #104170 - cjgillot:hir-def-id, r=fee1-dead
bors Nov 17, 2022
00ae5e1
Fix typo in `expect_used` and `unwrap_used` warning messages
smoelius Nov 17, 2022
82afb16
Add variant_name function to `LangItem`
flip1995 Nov 5, 2022
f7535e7
Rollup merge of #104483 - oli-obk:santa-clauses-make-goals, r=compile…
matthiaskrgr Nov 17, 2022
a09423f
Rm diagnostic item, use lang item
fee1-dead Jul 5, 2022
1c9c34d
Auto merge of #9858 - DesmondWillowbrook:never_loop, r=dswij
bors Nov 18, 2022
dfe37f1
Auto merge of #9850 - pheki:fix-7499-missing-ref, r=dswij
bors Nov 18, 2022
01f40ce
Auto merge of #9863 - smoelius:expect-unwrap-used-typo, r=flip1995
bors Nov 18, 2022
921f4d3
Keep original literal notation in suggestion
koka831 Nov 18, 2022
928a158
Allow manual swap in const fn
koka831 Nov 18, 2022
8749eda
Rollup merge of #104006 - flip1995:lang-items-clippy, r=oli-obk
matthiaskrgr Nov 18, 2022
d019fd9
Auto merge of #9855 - Alexendoo:needless-borrowed-ref-extra, r=xFrednet
bors Nov 18, 2022
3c86cad
Note about const fn
koka831 Nov 18, 2022
e144c7d
Auto merge of #9871 - koka831:fix/9864, r=xFrednet
bors Nov 18, 2022
bc01b2e
Auto merge of #101562 - nnethercote:shrink-ast-Expr-harder, r=petroch…
bors Nov 18, 2022
f6d4ef9
Auto merge of #104573 - matthiaskrgr:rollup-k36ybtp, r=matthiaskrgr
bors Nov 18, 2022
3a2eaa7
drive-by: Add is_async fn to hir::IsAsync
compiler-errors Nov 19, 2022
f60186f
Auto merge of #9800 - Alexendoo:def_path_res_multiple, r=dswij
bors Nov 19, 2022
ef5f602
Move `line_span` to source.rs
smoelius Nov 18, 2022
98b343c
[arithmetic-side-effects] Detect overflowing associated constants of …
c410-f3r Nov 19, 2022
e0b1463
Remove unused
c410-f3r Nov 19, 2022
1baa6cd
refac: grab a snip from receiver
koka831 Nov 19, 2022
27c4c17
Rollup merge of #104593 - compiler-errors:rpitit-object-safety-spans,…
matthiaskrgr Nov 19, 2022
80a4699
Auto merge of #98914 - fee1-dead-contrib:min-deref-patterns, r=compil…
bors Nov 20, 2022
4d8af99
Fix `#[allow]` for module_name_repetitions & single_component_path_im…
Alexendoo Nov 19, 2022
d445ced
Auto merge of #9879 - Alexendoo:allow, r=Manishearth
bors Nov 20, 2022
a85c8f3
Auto merge of #9870 - koka831:unformat-unused-rounding, r=Jarcho
bors Nov 20, 2022
e0c1959
Auto merge of #9592 - c410-f3r:arith, r=Jarcho
bors Nov 20, 2022
51ec465
Auto merge of #9873 - smoelius:move-line-span, r=flip1995
bors Nov 21, 2022
fd5b85c
Merge remote-tracking branch 'upstream/master' into rustup
flip1995 Nov 21, 2022
25e98bf
Bump Clippy version -> 0.1.67
flip1995 Nov 21, 2022
661f13c
Bump nightly version -> 2022-11-21
flip1995 Nov 21, 2022
5907e91
pass clippy sysroot env if given r=ozkanonur
onur-ozkan Nov 19, 2022
05b914a
Fix custom ICE message test on windows
flip1995 Nov 21, 2022
f4850f7
Auto merge of #9881 - flip1995:rustup, r=flip1995
bors Nov 21, 2022
ddf055a
Merge commit 'f4850f7292efa33759b4f7f9b7621268979e9914' into clippyup
flip1995 Nov 21, 2022
d407778
Update Cargo.lock
flip1995 Nov 21, 2022
b4c90ab
Fix declare_clippy_lint crate
flip1995 Nov 21, 2022
2422802
Clippy: Don't import GenericParamDefKind
flip1995 Nov 21, 2022
5e6a9a4
Clippy: Workaround for let_chains issue
flip1995 Nov 22, 2022
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
  •  
  •  
  •  
21 changes: 15 additions & 6 deletions Cargo.lock
Original file line number Diff line number Diff line change
Expand Up @@ -652,7 +652,7 @@ dependencies = [

[[package]]
name = "clippy"
version = "0.1.66"
version = "0.1.67"
dependencies = [
"clippy_lints",
"clippy_utils",
Expand Down Expand Up @@ -689,16 +689,16 @@ dependencies = [
"itertools",
"opener",
"shell-escape",
"tempfile",
"walkdir",
]

[[package]]
name = "clippy_lints"
version = "0.1.66"
version = "0.1.67"
dependencies = [
"cargo_metadata 0.14.0",
"clippy_utils",
"declare_clippy_lint",
"if_chain",
"itertools",
"pulldown-cmark",
Expand All @@ -717,7 +717,7 @@ dependencies = [

[[package]]
name = "clippy_utils"
version = "0.1.66"
version = "0.1.67"
dependencies = [
"arrayvec",
"if_chain",
Expand Down Expand Up @@ -1044,6 +1044,15 @@ version = "2.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a0afaad2b26fa326569eb264b1363e8ae3357618c43982b3f285f0774ce76b69"

[[package]]
name = "declare_clippy_lint"
version = "0.1.67"
dependencies = [
"itertools",
"quote",
"syn",
]

[[package]]
name = "derive-new"
version = "0.5.8"
Expand Down Expand Up @@ -2850,9 +2859,9 @@ checksum = "07589615d719a60c8dd8a4622e7946465dfef20d1a428f969e3443e7386d5f45"

[[package]]
name = "quote"
version = "1.0.18"
version = "1.0.21"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a1feb54ed693b93a84e14094943b84b7c4eae204c512b7ccb95ab0c66d278ad1"
checksum = "bbe448f377a7d6961e30f5955f9b8d106c3f5e449d493ee1b125c1d43c2b5179"
dependencies = [
"proc-macro2",
]
Expand Down
159 changes: 156 additions & 3 deletions src/tools/clippy/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,157 @@ All notable changes to this project will be documented in this file.
See [Changelog Update](book/src/development/infrastructure/changelog_update.md) if you want to update this
document.

## Unreleased / In Rust Nightly
## Unreleased / Beta / In Rust Nightly

[3c7e7dbc...master](https://github.com/rust-lang/rust-clippy/compare/3c7e7dbc...master)
[b52fb523...master](https://github.com/rust-lang/rust-clippy/compare/b52fb523...master)

## Rust 1.65

Current stable, released 2022-11-03

[3c7e7dbc...b52fb523](https://github.com/rust-lang/rust-clippy/compare/3c7e7dbc...b52fb523)

### Important Changes

* Clippy now has an `--explain <LINT>` command to show the lint description in the console
[#8952](https://github.com/rust-lang/rust-clippy/pull/8952)

### New Lints

* [`unused_peekable`]
[#9258](https://github.com/rust-lang/rust-clippy/pull/9258)
* [`collapsible_str_replace`]
[#9269](https://github.com/rust-lang/rust-clippy/pull/9269)
* [`manual_string_new`]
[#9295](https://github.com/rust-lang/rust-clippy/pull/9295)
* [`iter_on_empty_collections`]
[#9187](https://github.com/rust-lang/rust-clippy/pull/9187)
* [`iter_on_single_items`]
[#9187](https://github.com/rust-lang/rust-clippy/pull/9187)
* [`bool_to_int_with_if`]
[#9412](https://github.com/rust-lang/rust-clippy/pull/9412)
* [`multi_assignments`]
[#9379](https://github.com/rust-lang/rust-clippy/pull/9379)
* [`result_large_err`]
[#9373](https://github.com/rust-lang/rust-clippy/pull/9373)
* [`partialeq_to_none`]
[#9288](https://github.com/rust-lang/rust-clippy/pull/9288)
* [`suspicious_to_owned`]
[#8984](https://github.com/rust-lang/rust-clippy/pull/8984)
* [`cast_slice_from_raw_parts`]
[#9247](https://github.com/rust-lang/rust-clippy/pull/9247)
* [`manual_instant_elapsed`]
[#9264](https://github.com/rust-lang/rust-clippy/pull/9264)

### Moves and Deprecations

* Moved [`significant_drop_in_scrutinee`] to `nursery` (now allow-by-default)
[#9302](https://github.com/rust-lang/rust-clippy/pull/9302)
* Rename `logic_bug` to [`overly_complex_bool_expr`]
[#9306](https://github.com/rust-lang/rust-clippy/pull/9306)
* Rename `arithmetic` to [`arithmetic_side_effects`]
[#9443](https://github.com/rust-lang/rust-clippy/pull/9443)
* Moved [`only_used_in_recursion`] to complexity (now warn-by-default)
[#8804](https://github.com/rust-lang/rust-clippy/pull/8804)
* Moved [`assertions_on_result_states`] to restriction (now allow-by-default)
[#9273](https://github.com/rust-lang/rust-clippy/pull/9273)
* Renamed `blacklisted_name` to [`disallowed_names`]
[#8974](https://github.com/rust-lang/rust-clippy/pull/8974)

### Enhancements

* [`option_if_let_else`]: Now also checks for match expressions
[#8696](https://github.com/rust-lang/rust-clippy/pull/8696)
* [`explicit_auto_deref`]: Now lints on implicit returns in closures
[#9126](https://github.com/rust-lang/rust-clippy/pull/9126)
* [`needless_borrow`]: Now considers trait implementations
[#9136](https://github.com/rust-lang/rust-clippy/pull/9136)
* [`suboptimal_flops`], [`imprecise_flops`]: Now lint on constant expressions
[#9404](https://github.com/rust-lang/rust-clippy/pull/9404)
* [`if_let_mutex`]: Now detects mutex behind references and warns about deadlocks
[#9318](https://github.com/rust-lang/rust-clippy/pull/9318)

### False Positive Fixes

* [`unit_arg`] [`default_trait_access`] [`missing_docs_in_private_items`]: No longer
trigger in code generated from proc-macros
[#8694](https://github.com/rust-lang/rust-clippy/pull/8694)
* [`unwrap_used`]: Now lints uses of `unwrap_err`
[#9338](https://github.com/rust-lang/rust-clippy/pull/9338)
* [`expect_used`]: Now lints uses of `expect_err`
[#9338](https://github.com/rust-lang/rust-clippy/pull/9338)
* [`transmute_undefined_repr`]: Now longer lints if the first field is compatible
with the other type
[#9287](https://github.com/rust-lang/rust-clippy/pull/9287)
* [`unnecessary_to_owned`]: No longer lints, if type change cased errors in
the caller function
[#9424](https://github.com/rust-lang/rust-clippy/pull/9424)
* [`match_like_matches_macro`]: No longer lints, if there are comments inside the
match expression
[#9276](https://github.com/rust-lang/rust-clippy/pull/9276)
* [`partialeq_to_none`]: No longer trigger in code generated from macros
[#9389](https://github.com/rust-lang/rust-clippy/pull/9389)
* [`arithmetic_side_effects`]: No longer lints expressions that only use literals
[#9365](https://github.com/rust-lang/rust-clippy/pull/9365)
* [`explicit_auto_deref`]: Now ignores references on block expressions when the type
is `Sized`, on `dyn Trait` returns and when the suggestion is non-trivial
[#9126](https://github.com/rust-lang/rust-clippy/pull/9126)
* [`trait_duplication_in_bounds`]: Now better tracks bounds to avoid false positives
[#9167](https://github.com/rust-lang/rust-clippy/pull/9167)
* [`format_in_format_args`]: Now suggests cases where the result is formatted again
[#9349](https://github.com/rust-lang/rust-clippy/pull/9349)
* [`only_used_in_recursion`]: No longer lints on function without recursions and
takes external functions into account
[#8804](https://github.com/rust-lang/rust-clippy/pull/8804)
* [`missing_const_for_fn`]: No longer lints in proc-macros
[#9308](https://github.com/rust-lang/rust-clippy/pull/9308)
* [`non_ascii_literal`]: Allow non-ascii comments in tests and make sure `#[allow]`
attributes work in tests
[#9327](https://github.com/rust-lang/rust-clippy/pull/9327)
* [`question_mark`]: No longer lint `if let`s with subpatterns
[#9348](https://github.com/rust-lang/rust-clippy/pull/9348)
* [`needless_collect`]: No longer lints in loops
[#8992](https://github.com/rust-lang/rust-clippy/pull/8992)
* [`mut_mutex_lock`]: No longer lints if the mutex is behind an immutable reference
[#9418](https://github.com/rust-lang/rust-clippy/pull/9418)
* [`needless_return`]: Now ignores returns with arguments
[#9381](https://github.com/rust-lang/rust-clippy/pull/9381)
* [`range_plus_one`], [`range_minus_one`]: Now ignores code with macros
[#9446](https://github.com/rust-lang/rust-clippy/pull/9446)
* [`assertions_on_result_states`]: No longer lints on the unit type
[#9273](https://github.com/rust-lang/rust-clippy/pull/9273)

### Suggestion Fixes/Improvements

* [`unwrap_or_else_default`]: Now suggests `unwrap_or_default()` for empty strings
[#9421](https://github.com/rust-lang/rust-clippy/pull/9421)
* [`if_then_some_else_none`]: Now also suggests `bool::then_some`
[#9289](https://github.com/rust-lang/rust-clippy/pull/9289)
* [`redundant_closure_call`]: The suggestion now works for async closures
[#9053](https://github.com/rust-lang/rust-clippy/pull/9053)
* [`suboptimal_flops`]: Now suggests parenthesis when they are required
[#9394](https://github.com/rust-lang/rust-clippy/pull/9394)
* [`case_sensitive_file_extension_comparisons`]: Now suggests `map_or(..)` instead of `map(..).unwrap_or`
[#9341](https://github.com/rust-lang/rust-clippy/pull/9341)
* Deprecated configuration values can now be updated automatically
[#9252](https://github.com/rust-lang/rust-clippy/pull/9252)
* [`or_fun_call`]: Now suggest `Entry::or_default` for `Entry::or_insert(Default::default())`
[#9342](https://github.com/rust-lang/rust-clippy/pull/9342)
* [`unwrap_used`]: Only suggests `expect` if [`expect_used`] is allowed
[#9223](https://github.com/rust-lang/rust-clippy/pull/9223)

### ICE Fixes

* Fix ICE in [`useless_format`] for literals
[#9406](https://github.com/rust-lang/rust-clippy/pull/9406)
* Fix infinite loop in [`vec_init_then_push`]
[#9441](https://github.com/rust-lang/rust-clippy/pull/9441)
* Fix ICE when reading literals with weird proc-macro spans
[#9303](https://github.com/rust-lang/rust-clippy/pull/9303)

## Rust 1.64

Current stable, released 2022-09-22
Released 2022-09-22

[d7b5cbf0...3c7e7dbc](https://github.com/rust-lang/rust-clippy/compare/d7b5cbf0...3c7e7dbc)

Expand Down Expand Up @@ -3903,6 +4047,7 @@ Released 2018-09-13
[`format_push_string`]: https://rust-lang.github.io/rust-clippy/master/index.html#format_push_string
[`from_iter_instead_of_collect`]: https://rust-lang.github.io/rust-clippy/master/index.html#from_iter_instead_of_collect
[`from_over_into`]: https://rust-lang.github.io/rust-clippy/master/index.html#from_over_into
[`from_raw_with_void_ptr`]: https://rust-lang.github.io/rust-clippy/master/index.html#from_raw_with_void_ptr
[`from_str_radix_10`]: https://rust-lang.github.io/rust-clippy/master/index.html#from_str_radix_10
[`future_not_send`]: https://rust-lang.github.io/rust-clippy/master/index.html#future_not_send
[`get_first`]: https://rust-lang.github.io/rust-clippy/master/index.html#get_first
Expand Down Expand Up @@ -3978,6 +4123,7 @@ Released 2018-09-13
[`len_zero`]: https://rust-lang.github.io/rust-clippy/master/index.html#len_zero
[`let_and_return`]: https://rust-lang.github.io/rust-clippy/master/index.html#let_and_return
[`let_underscore_drop`]: https://rust-lang.github.io/rust-clippy/master/index.html#let_underscore_drop
[`let_underscore_future`]: https://rust-lang.github.io/rust-clippy/master/index.html#let_underscore_future
[`let_underscore_lock`]: https://rust-lang.github.io/rust-clippy/master/index.html#let_underscore_lock
[`let_underscore_must_use`]: https://rust-lang.github.io/rust-clippy/master/index.html#let_underscore_must_use
[`let_unit_value`]: https://rust-lang.github.io/rust-clippy/master/index.html#let_unit_value
Expand All @@ -3996,6 +4142,8 @@ Released 2018-09-13
[`manual_find_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#manual_find_map
[`manual_flatten`]: https://rust-lang.github.io/rust-clippy/master/index.html#manual_flatten
[`manual_instant_elapsed`]: https://rust-lang.github.io/rust-clippy/master/index.html#manual_instant_elapsed
[`manual_is_ascii_check`]: https://rust-lang.github.io/rust-clippy/master/index.html#manual_is_ascii_check
[`manual_let_else`]: https://rust-lang.github.io/rust-clippy/master/index.html#manual_let_else
[`manual_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#manual_map
[`manual_memcpy`]: https://rust-lang.github.io/rust-clippy/master/index.html#manual_memcpy
[`manual_non_exhaustive`]: https://rust-lang.github.io/rust-clippy/master/index.html#manual_non_exhaustive
Expand Down Expand Up @@ -4198,6 +4346,8 @@ Released 2018-09-13
[`same_item_push`]: https://rust-lang.github.io/rust-clippy/master/index.html#same_item_push
[`same_name_method`]: https://rust-lang.github.io/rust-clippy/master/index.html#same_name_method
[`search_is_some`]: https://rust-lang.github.io/rust-clippy/master/index.html#search_is_some
[`seek_from_current`]: https://rust-lang.github.io/rust-clippy/master/index.html#seek_from_current
[`seek_to_start_instead_of_rewind`]: https://rust-lang.github.io/rust-clippy/master/index.html#seek_to_start_instead_of_rewind
[`self_assignment`]: https://rust-lang.github.io/rust-clippy/master/index.html#self_assignment
[`self_named_constructors`]: https://rust-lang.github.io/rust-clippy/master/index.html#self_named_constructors
[`self_named_module_files`]: https://rust-lang.github.io/rust-clippy/master/index.html#self_named_module_files
Expand Down Expand Up @@ -4247,6 +4397,7 @@ Released 2018-09-13
[`suspicious_splitn`]: https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_splitn
[`suspicious_to_owned`]: https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_to_owned
[`suspicious_unary_op_formatting`]: https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_unary_op_formatting
[`suspicious_xor_used_as_pow`]: https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_xor_used_as_pow
[`swap_ptr_to_ref`]: https://rust-lang.github.io/rust-clippy/master/index.html#swap_ptr_to_ref
[`tabs_in_doc_comments`]: https://rust-lang.github.io/rust-clippy/master/index.html#tabs_in_doc_comments
[`temporary_assignment`]: https://rust-lang.github.io/rust-clippy/master/index.html#temporary_assignment
Expand Down Expand Up @@ -4277,6 +4428,7 @@ Released 2018-09-13
[`try_err`]: https://rust-lang.github.io/rust-clippy/master/index.html#try_err
[`type_complexity`]: https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity
[`type_repetition_in_bounds`]: https://rust-lang.github.io/rust-clippy/master/index.html#type_repetition_in_bounds
[`unchecked_duration_subtraction`]: https://rust-lang.github.io/rust-clippy/master/index.html#unchecked_duration_subtraction
[`undocumented_unsafe_blocks`]: https://rust-lang.github.io/rust-clippy/master/index.html#undocumented_unsafe_blocks
[`undropped_manually_drops`]: https://rust-lang.github.io/rust-clippy/master/index.html#undropped_manually_drops
[`unicode_not_nfc`]: https://rust-lang.github.io/rust-clippy/master/index.html#unicode_not_nfc
Expand All @@ -4298,6 +4450,7 @@ Released 2018-09-13
[`unnecessary_mut_passed`]: https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_mut_passed
[`unnecessary_operation`]: https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_operation
[`unnecessary_owned_empty_strings`]: https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_owned_empty_strings
[`unnecessary_safety_doc`]: https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_safety_doc
[`unnecessary_self_imports`]: https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_self_imports
[`unnecessary_sort_by`]: https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_sort_by
[`unnecessary_to_owned`]: https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_to_owned
Expand Down
Loading