Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
124 commits
Select commit Hold shift + click to select a range
ba2989f
fix duplicate diagnostics for msrv attrs
Gri-ffin Jul 10, 2026
e5af49b
fix: `needless_range_loop` suggests wrongly for nested index
profetia Feb 25, 2026
8150f30
unnecessary_fold: lint folding over an Option's iterator
bugprone Jul 22, 2026
413edb1
review: lint only literal or Copy-binding inits, refactor to early re…
bugprone Jul 23, 2026
62deb46
review: use multipart_suggestion, reject closure params as init
bugprone Jul 26, 2026
a5a5326
review: add lintable nested inner test, rename to the _unfixable conv…
bugprone Jul 26, 2026
02fe0f2
replace `box_patterns` usage with `deref_patterns`
cyrgani May 13, 2026
284850a
support deref patterns in `unnested_or_patterns`
cyrgani Jul 30, 2026
96522c7
ci: upgrade cache action from v4 to v5
xtqqczze Aug 2, 2026
1aed118
ci: upgrade upload-artifact action from v4 to v7
xtqqczze Aug 2, 2026
a98a712
remove one weird version of let-else
CommanderStorm Aug 2, 2026
af7cef9
`mixed_read_write_in_expression`: fix broken link to reference
DanielEScherzer Aug 2, 2026
351b044
Instead of representing trait errors as `Vec<Error>`, use a special type
ChayimFriedman2 Jul 29, 2026
f0b8245
feat: add `unnecessary_nonzero_get` lint
saberoueslati Aug 6, 2026
3fba180
Merge commit '49e2f89a2605a9a340e04955fdbefa9803e6027a' into clippy-s…
flip1995 Aug 7, 2026
cff7b66
Fix `needless_range_loop` suggests wrongly for nested index (#16634)
ada4a Aug 8, 2026
e788c98
New lint/nonzero operators and methods (#17499)
samueltardieu Aug 8, 2026
e62982b
`needless_range_loop`: put `.enumerate()` into backticks
ada4a Jul 12, 2026
76e7e12
Fix up `lang_items` import paths
mejrs Aug 9, 2026
f9b8ed6
Fix cast_possible_truncation suggested fix replaces macro with defini…
AnHoang-alex Aug 9, 2026
a415293
RELICENSE_DOCUMENTATION.md: add closing parenthesis, remove empty line
DanielEScherzer Aug 10, 2026
f7816ac
fix: set CARGO_TERM_COLOR=never in tests
martinthomson Aug 10, 2026
b982647
Fix funding link
makai410 Aug 10, 2026
3a9ae38
Fix funding link (#17534)
dswij Aug 10, 2026
3317688
[cast_possible_truncation]: fix try_from suggestion expanding macros …
dswij Aug 10, 2026
048350b
fix: set CARGO_TERM_COLOR=never in tests (#17533)
dswij Aug 10, 2026
330f7a7
RELICENSE_DOCUMENTATION.md: add closing parenthesis, remove empty lin…
blyxyas Aug 10, 2026
673a9d8
rename `HostEffectPredicate` to `HostEffectClause`
ada4a Aug 10, 2026
dded2db
ci: Bump Node.js 20 GitHub Actions (#17493)
flip1995 Aug 10, 2026
017ae33
needless_bool: lint the early-return guard form
sylvestre Aug 10, 2026
64db4f3
needless_bool: lint the early-return guard form (#17185)
blyxyas Aug 10, 2026
15e99c9
Build docs into the `main` directory
Kobzol Aug 11, 2026
8fb0b61
Don't lint semicolon_if_nothing_returned in #[automatically_derived] …
Jun 13, 2026
111573a
Build docs into the `main` directory (#17541)
blyxyas Aug 11, 2026
d630cd5
Don't lint semicolon_if_nothing_returned in #[automatically_derived] …
dswij Aug 11, 2026
d33e59f
Suggest Result variant queries in unnecessary_map_or
fzlzjerry Aug 10, 2026
2bc35de
Fix errors in tooling
JonathanBrouwer Aug 11, 2026
7c10243
rename unecessary_nonzero_get to needless_nonzero_get
Gri-ffin Aug 11, 2026
b34942c
fix: avoid double_must_use in macro-generated code
saberoueslati Aug 11, 2026
907246a
Rename `unecessary_nonzero_get` to `needless_nonzero_get` (#17538)
rustbot Aug 11, 2026
fb88aa4
Add myself back into review rotation
blyxyas Aug 12, 2026
fb16323
Add myself back into review rotation (#17551)
blyxyas Aug 12, 2026
831dc91
Modify doc links to point to `main` instead of `master`
Kobzol Aug 12, 2026
9a73ad8
Modify doc links to point to `main` instead of `master` (#17552)
rustbot Aug 12, 2026
3013083
Clean-up `used_underscore_*`
Jarcho Jun 23, 2026
dc22b72
Rewrite and extend `used_underscore_*` tests.
Jarcho Aug 11, 2026
d2c4d15
replace `box_patterns` usage with `deref_patterns` (#17008)
blyxyas Aug 13, 2026
e16c281
fix ICE on unnecessary_rest_pattern for TyAlias
dswij Aug 13, 2026
5682b1b
fix ICE on unnecessary_rest_pattern for TyAlias (#17557)
dswij Aug 14, 2026
6555be8
clippy: Remove `eq_coroutine_kind`
nnethercote Aug 14, 2026
e525019
Fix duplicate diagnostics for `min_rust_version_invalid_attr` (#17396)
dswij Aug 14, 2026
f1f010d
old commented code cleanup
dswij Aug 14, 2026
391c87a
fix: don't suppress lint when return expr has lint level attributes
Gri-ffin May 21, 2026
282cfce
fix: allow WebAuthn in doc markdown
rajanpanth Aug 15, 2026
366cabf
chore: remove one weird macro-version of let-else (#17496)
ada4a Aug 15, 2026
41d6aaa
`mixed_read_write_in_expression`: fix broken link to reference (#17491)
ada4a Aug 15, 2026
7a637d3
clenaup old commented code (#17559)
Manishearth Aug 15, 2026
6369b49
Clean-up `used_underscore_*` (#17308)
llogiq Aug 16, 2026
8b9906d
Add `option_zip_none` lint
Amit5601 Jul 27, 2026
a27486f
Avoid manual_assert_eq for byte slices
fyrsta7 Aug 16, 2026
2bddb2b
perf: run in_external_macro after the cheap checks in five hot lint p…
xmakro Aug 16, 2026
59efa0e
fix `unfulfilled_lint_expectations` incorrectly triggered by `#[expec…
blyxyas Aug 16, 2026
b6841a2
Overhaul `CoroutineKind`
nnethercote Aug 14, 2026
12e6ea9
Document byte slice limitation
fyrsta7 Aug 17, 2026
e084aed
Replace Gated with Option in the combined late pass
Alexendoo Aug 17, 2026
474543b
fix: allow WebAuthn in doc markdown (#17568)
Alexendoo Aug 17, 2026
a11d780
perf: run in_external_macro after the cheap checks in five hot lint p…
Jarcho Aug 17, 2026
8125bdd
`needless_range_loop`: put `.enumerate()` into backticks (#17413)
Manishearth Aug 17, 2026
532d3e9
perf: resolve the callee before the expansion walk in VecArgs::hir
xmakro Aug 17, 2026
cfd2f88
review: skip mut accumulator bindings
bugprone Aug 17, 2026
af35cdf
perf: check first_node_in_macro before the root macro walk in useless…
xmakro Aug 17, 2026
b90fbe4
Replace Gated with Option in the combined late pass (#17579)
rustbot Aug 17, 2026
c78f888
perf: resolve the callee before the expansion walk in VecArgs::hir (#…
rustbot Aug 17, 2026
f077229
addressed review comment
saberoueslati Aug 18, 2026
b6a86cf
perf: check fn kind before the expansion walk in missing_const_for_th…
xmakro Aug 17, 2026
bc72fa3
Initial implementation of `FnPtr` trait
carbotaniuman Aug 18, 2026
8d0cfc3
- implement `GenericArgs::terms` and use where needed.
LorrensP-2158466 Jul 24, 2026
23aabd0
use `next().and_then(as_type)` instead of `filter_map(as_type).nth(0)`
LorrensP-2158466 Aug 8, 2026
68bbbb3
perf: check fn kind before the expansion walk in missing_const_for_th…
rustbot Aug 18, 2026
aff2649
Trigger `integer_division_remainder_used` on `DivAssign`/`RemAssign`
lapla-cogito Feb 1, 2026
136c8be
Changelog for Clippy 1.98
alex-semenyuk Aug 17, 2026
ea48a0f
enable next solver on nightly
Kivooeo Aug 6, 2026
a19ecd6
Add `option_zip_none` lint (#17465)
ada4a Aug 18, 2026
6175f80
Trigger `integer_division_remainder_used` on `DivAssign`/`RemAssign` …
dswij Aug 18, 2026
191ddc8
perf: check first_node_in_macro before the root macro walk in useless…
rustbot Aug 18, 2026
a1f614c
test: document default_trait_access suggestion as unfixable
rajanpanth Aug 19, 2026
236bc3e
rename `ProjectionPredicate` to `ProjectionClause`
ada4a Aug 18, 2026
e1bb6a1
rename `TraitPredicate` to `TraitClause`
ada4a Aug 12, 2026
a184fd6
Changelog for Clippy 1.98 🍎 (#17578)
rustbot Aug 19, 2026
3457f1c
Don't fire `manual_contains` when both sides use the slice element
lapla-cogito Aug 15, 2026
0ba39a5
Don't fire `manual_contains` when both sides use the slice element (#…
blyxyas Aug 19, 2026
bdce5b9
fix: avoid double_must_use in macro-generated code (#17547)
blyxyas Aug 19, 2026
6136fbd
Document and simplify Result bool matching
fzlzjerry Aug 20, 2026
bb5b5d0
Remove broken suggestion for blocks_in_conditions
Jun 1, 2026
a589700
Remove broken suggestion for blocks_in_conditions (#17127)
blyxyas Aug 20, 2026
1495aea
Merge remote-tracking branch 'upstream/master' into rustup
flip1995 Aug 20, 2026
791f0fa
Bump nightly version -> 2026-08-20
flip1995 Aug 20, 2026
9a2827d
Bump Clippy version -> 0.1.100
flip1995 Aug 20, 2026
0711379
Fix compile-test due to cargo update
flip1995 Aug 20, 2026
21baba9
Rustup (#17591)
flip1995 Aug 20, 2026
a025262
Install cargo tools with locked dependencies
konstin Aug 20, 2026
53565a5
Remove changes that belong in other repositories
konstin Aug 20, 2026
3bab727
Fix clippy/rustdoc
mejrs Aug 13, 2026
e8bea03
Suggest is_ok/is_err for boolean Result mappings (#17537)
Manishearth Aug 20, 2026
f7a1ce8
Fix tools
mejrs Aug 17, 2026
980c299
Auto merge of #160619 - Kivooeo:enable-next-solver, r=lcnr,jdonszelma…
bors Aug 21, 2026
4f4dd4c
Rollup merge of #161259 - mejrs:attr_structures, r=JonathanBrouwer
jhpratt Aug 21, 2026
854598d
Rollup merge of #159899 - LorrensP-2158466:generic_args_terms, r=khyp…
jhpratt Aug 21, 2026
6943d70
Make needless_bool less aggressive for chained `if`s
flip1995 Aug 21, 2026
b962eb8
Make needless_bool less aggressive for chained `if`s (#17598)
flip1995 Aug 21, 2026
a46af27
test: document default_trait_access suggestion as unfixable (#17569)
Alexendoo Aug 21, 2026
cde6ea0
unnecessary_fold: lint folding over an Option's iterator (#17445)
llogiq Aug 22, 2026
e57f468
Avoid `manual_assert_eq` for byte slice-like types (#17575)
llogiq Aug 22, 2026
9ec68e8
Fix large_futures ICE with the next solver
tamird Aug 22, 2026
62fa897
Rollup merge of #161428 - konstin:konsti/cargo-install-locked, r=folk…
JonathanBrouwer Aug 22, 2026
d6c913c
Refer to Zulip channel with its new name #t-clippy
miikkas Aug 23, 2026
cc7fb2d
Refer to Zulip channel with its new name #t-clippy (#17610)
Manishearth Aug 23, 2026
c58c138
Fix large_futures ICE with the next solver (#17601)
flip1995 Aug 23, 2026
1ec4db5
Merge remote-tracking branch 'upstream/master' into rustup
flip1995 Aug 23, 2026
f9d42d4
Bump nightly version -> 2026-08-23
flip1995 Aug 23, 2026
7c06e7c
Rustup (#17607)
flip1995 Aug 23, 2026
c9d0ec7
Merge commit '7c06e7c42a8b56f9c1ac20e9ce34cadca0fce100' into clippy-s…
flip1995 Aug 23, 2026
aa2f8d2
Update Cargo.lock
flip1995 Aug 23, 2026
be9e487
Fix clippy::needless_bool fallout
flip1995 Aug 21, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions Cargo.lock
Original file line number Diff line number Diff line change
Expand Up @@ -659,7 +659,7 @@ checksum = "c8d4a3bb8b1e0c1050499d1815f5ab16d04f0959b233085fb31653fbfc9d98f9"

[[package]]
name = "clippy"
version = "0.1.99"
version = "0.1.100"
dependencies = [
"anstream 0.6.21",
"askama",
Expand All @@ -684,7 +684,7 @@ dependencies = [

[[package]]
name = "clippy_config"
version = "0.1.99"
version = "0.1.100"
dependencies = [
"arrayvec",
"clippy_utils",
Expand All @@ -708,7 +708,7 @@ dependencies = [

[[package]]
name = "clippy_lints"
version = "0.1.99"
version = "0.1.100"
dependencies = [
"arrayvec",
"cargo_metadata 0.23.1",
Expand Down Expand Up @@ -739,7 +739,7 @@ dependencies = [

[[package]]
name = "clippy_utils"
version = "0.1.99"
version = "0.1.100"
dependencies = [
"arrayvec",
"itertools",
Expand Down Expand Up @@ -1153,7 +1153,7 @@ checksum = "a0afaad2b26fa326569eb264b1363e8ae3357618c43982b3f285f0774ce76b69"

[[package]]
name = "declare_clippy_lint"
version = "0.1.99"
version = "0.1.100"

[[package]]
name = "derive-where"
Expand Down
12 changes: 6 additions & 6 deletions compiler/rustc_hir_analysis/src/hir_ty_lowering/dyn_trait.rs
Original file line number Diff line number Diff line change
Expand Up @@ -401,12 +401,12 @@ impl<'tcx> dyn HirTyLowerer<'tcx> + '_ {

// Like for trait refs, verify that `dummy_self` did not leak inside default type
// parameters.
let references_self = b.projection_term.args.iter().skip(1).any(|arg| {
if arg.walk().any(|arg| arg == dummy_self.into()) {
return true;
}
false
});
let references_self = b
.projection_term
.args
.iter()
.skip(1)
.any(|arg| arg.walk().any(|arg| arg == dummy_self.into()));
if references_self {
let guar = tcx
.dcx()
Expand Down
6 changes: 1 addition & 5 deletions compiler/rustc_mir_transform/src/inline.rs
Original file line number Diff line number Diff line change
Expand Up @@ -343,11 +343,7 @@ impl<'tcx> Inliner<'tcx> for NormalInliner<'tcx> {
// Avoid inlining into coroutines, since their `optimized_mir` is used for layout computation,
// which can create a cycle, even when no attempt is made to inline the function in the other
// direction.
if body.coroutine.is_some() {
return false;
}

true
body.coroutine.is_none()
}

#[instrument(level = "debug", skip(self, callee_body))]
Expand Down
7 changes: 1 addition & 6 deletions compiler/rustc_trait_selection/src/traits/coherence.rs
Original file line number Diff line number Diff line change
Expand Up @@ -698,12 +698,7 @@ fn try_prove_negated_where_clause<'tcx>(
// FIXME: We could use the assumed_wf_types from both impls, I think,
// if that wasn't implemented just for LocalDefId, and we'd need to do
// the normalization ourselves since this is totally fallible...
let errors = ocx.resolve_regions(CRATE_DEF_ID, param_env, []);
if !errors.is_empty() {
return false;
}

true
ocx.resolve_regions(CRATE_DEF_ID, param_env, []).is_empty()
}

/// Compute the `intercrate_ambiguity_causes` for the new solver using
Expand Down
7 changes: 1 addition & 6 deletions compiler/rustc_trait_selection/src/traits/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -863,12 +863,7 @@ pub fn impossible_clauses<'tcx>(tcx: TyCtxt<'tcx>, clauses: Vec<ty::Clause<'tcx>
// vs user-written impls to AMBIGUOUS, this may return ambiguity even
// with no infer vars. There may also be ways to encounter ambiguity due
// to post-mono overflow.
let true_errors = ocx.try_evaluate_obligations();
if !true_errors.no_errors() {
return true;
}

false
!ocx.try_evaluate_obligations().no_errors()

@flip1995 flip1995 Aug 23, 2026

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is basically .has_errors(), but I wasn't sure whether the !.no_errors() was intentional, in case the Errors enum is extended in the future 🤷 Or if HasErrors(vec![]) with an empty vec should also not be considered.

View changes since the review

}

fn instantiate_and_check_impossible_clauses<'tcx>(
Expand Down
11 changes: 4 additions & 7 deletions src/bootstrap/src/core/build_steps/llvm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -372,13 +372,10 @@ pub(crate) fn is_ci_llvm_available_for_target(
("x86_64-unknown-netbsd", false),
];

if !supported_platforms.contains(&(&*host_target.triple, asserts))
&& (asserts || !supported_platforms.contains(&(&*host_target.triple, true)))
{
return false;
}

true
// Check if the host target is available with the requested assertions (true/false),
supported_platforms.contains(&(&*host_target.triple, asserts))
// if it is not available for the given `asserts`, check if it is available with assertions (superset).
|| supported_platforms.contains(&(&*host_target.triple, true))
Comment on lines +375 to +378

@flip1995 flip1995 Aug 23, 2026

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be equivalent, but also way easier to understand. Please double check.

View changes since the review

}

#[derive(Clone)]
Expand Down
6 changes: 1 addition & 5 deletions src/bootstrap/src/core/build_steps/setup.rs
Original file line number Diff line number Diff line change
Expand Up @@ -375,11 +375,7 @@ fn ensure_stage1_toolchain_placeholder_exists(stage_path: &str) -> bool {

// Take care not to overwrite the file
let result = File::options().append(true).create(true).open(&pathbuf);
if result.is_err() {
return false;
}

true
result.is_ok()
}

// Used to get the path for `Subcommand::Setup`
Expand Down
2 changes: 1 addition & 1 deletion src/tools/clippy/.github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
github: rustfoundation
custom: [ "rust-lang.org/funding" ]
custom: [ "https://rust-lang.org/funding" ]
4 changes: 4 additions & 0 deletions src/tools/clippy/.github/deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ set -ex

echo "Removing the current docs for master"
rm -rf out/master/ || exit 0
rm -rf out/main/ || exit 0

echo "Making the docs for master"
mkdir out/master/
Expand All @@ -12,6 +13,9 @@ cp util/gh-pages/theme.js out/master
cp util/gh-pages/script.js out/master
cp util/gh-pages/style.css out/master

echo "Copying the docs into the main directory"
cp -Tr out/master/ out/main/

if [[ -n $TAG_NAME ]]; then
echo "Save the doc for the current tag ($TAG_NAME) and point stable/ to it"
cp -Tr out/master "out/$TAG_NAME"
Expand Down
Loading
Loading