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

Clippy subtree sync #117979

Merged
merged 84 commits into from
Nov 16, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
84 commits
Select commit Hold shift + click to select a range
a799249
Add additional branches to hir_utils::eq_expr
Oct 24, 2023
ed982af
Expliticly specify else branches in hir_utils::hash_expr
Oct 30, 2023
67d379b
Reorder ExprKinds in eq_expr to alphabetical
Oct 30, 2023
6d84065
Add branches in eq_expr
Oct 31, 2023
57a4644
Fix `dbg_macro` semi span calculation
Alexendoo Nov 1, 2023
aae86cc
Rename hook.
cjgillot Oct 31, 2023
e1ec2d5
Minimize `pub` usage in `source_map.rs`.
nnethercote Nov 2, 2023
77c1e3a
Merge commit '09ac14c901abc43bd0d617ae4a44e8a4fed98d9c' into clippyup
flip1995 Nov 2, 2023
902c79c
Auto merge of #11743 - Alexendoo:dbg-macro-stmt-span, r=xFrednet
bors Nov 2, 2023
2d9af16
Auto merge of #117507 - nnethercote:rustc_span, r=Nilstrieb
bors Nov 3, 2023
294df80
[`unused_enumerate_index`]: don't ICE on empty tuples
y21 Nov 3, 2023
789bc73
Auto merge of #11756 - y21:issue11755, r=Manishearth
bors Nov 3, 2023
b9efa3e
update references of `clippy_utils::msrvs` and `clippy_lints::util::c…
y21 Nov 4, 2023
17c7d21
Warn when lint level is set on a match arm
Nadrieril Oct 23, 2023
67cc4b0
fix clippy author and failing test
dnbln Nov 4, 2023
6d9516a
Auto merge of #11758 - y21:clippy_config_references, r=flip1995
bors Nov 6, 2023
171845d
Reorder ExprKinds in hash_expr alphabetically
Nov 6, 2023
ba43632
Auto merge of #11736 - gernot-ohner:issue-10267, r=flip1995
bors Nov 8, 2023
73b9841
remove unnecessary `find_map` calls
Jacherr Nov 8, 2023
3a91a11
add logic to check allocator matching
Jacherr Nov 8, 2023
399fe32
[arc_with_non_send_sync] Improve suggested resolution
m-rph Nov 7, 2023
7932560
update testcases, cleanup
Jacherr Nov 8, 2023
e16d42f
Auto merge of #11772 - partiallytyped:11714, r=blyxyas
bors Nov 8, 2023
67bb503
add support for std::alloc::Global, add more tests
Jacherr Nov 8, 2023
b6d56c4
add no-rustfix since suggestions are invalid
Jacherr Nov 8, 2023
483b109
cargo dev fmt
Jacherr Nov 8, 2023
7e716ff
[`mod_module_files`] Don't emit lint for modules in tests
m-rph Nov 8, 2023
7cdaa3b
replace incorrect bool
Jacherr Nov 8, 2023
34b7d15
Auto merge of #11779 - partiallytyped:11775, r=blyxyas
bors Nov 8, 2023
16d58a2
Lift `expr_diverges` to `clippy_utils` as `is_never_expr`
Jarcho Nov 7, 2023
a44bb07
Change divergence checking to match the compiler's type system based …
Jarcho Nov 9, 2023
eabc64f
add additonal non-trigger testcase
Jacherr Nov 9, 2023
6be0f74
Auto merge of #11780 - Jacherr:vec-allocator-nolint, r=xFrednet
bors Nov 9, 2023
9681b4a
Run `if-to-let-chain clippy*/**/*.rs`
Alexendoo Nov 10, 2023
13b4bb1
Clean up after if chain removal
Alexendoo Nov 2, 2023
9a4dd10
Auto merge of #11750 - Alexendoo:let-chains, r=flip1995
bors Nov 10, 2023
f1979d4
Destructure `Conf` in `register_lints`
Alexendoo Nov 10, 2023
cb90674
add iter_over_hash_type lint
Jacherr Nov 11, 2023
7bc39f3
format and fix examples
Jacherr Nov 11, 2023
4a0c36d
Auto merge of #11790 - Alexendoo:destructure-conf, r=Manishearth
bors Nov 11, 2023
b2cf8f7
[`map_identity`]: respect match ergonomics
y21 Nov 11, 2023
d487579
Auto merge of #11792 - y21:issue11764, r=llogiq
bors Nov 11, 2023
a68cd88
Lint `needless_borrow` on most union field accesses
Jarcho Sep 14, 2023
4dead77
add type details to unnecessary_fallible_conversions note
matthri Nov 7, 2023
1a01132
Lint `explicit_auto_deref` on most union field accesses.
Jarcho Sep 15, 2023
9411648
implement more types to lint, fix wording
Jacherr Nov 11, 2023
938984a
run cargo dev fmt
Jacherr Nov 11, 2023
8ee9a9c
Auto merge of #11767 - matthri:unnecessary-fallible-conversions-ext-n…
bors Nov 11, 2023
886d5fb
Auto merge of #11508 - Jarcho:issue_11474, r=blyxyas
bors Nov 12, 2023
6a15f3b
Auto merge of #11787 - Jarcho:divergence_check, r=dswij
bors Nov 12, 2023
661e91b
Add test
compiler-errors Nov 5, 2023
1539eb8
Don't check for late-bound vars, check for escaping bound vars
compiler-errors Nov 5, 2023
07bc130
Auto merge of #11760 - compiler-errors:escaping, r=Jarcho
bors Nov 12, 2023
d89890d
move `suspicious_doc_comments` to doc pass
y21 Nov 13, 2023
a4b2864
Auto merge of #11798 - y21:move_sus_doc_comments, r=flip1995
bors Nov 13, 2023
c4971f9
rename `ReLateBound` to `ReBound`
lcnr Nov 13, 2023
9ab054d
update type flags
lcnr Nov 13, 2023
5a85822
Remove Centri3 from reviewer rotation
blyxyas Nov 13, 2023
f8ea496
add tests for type-aliased hash types
Jacherr Nov 13, 2023
c3a6b37
Auto merge of #11800 - blyxyas:meow-meow, r=Centri3
bors Nov 13, 2023
48f38eb
`needless_return_with_question_mark` ignore let-else
dswij Nov 13, 2023
3f6b29a
[`impl_trait_in_params`]: fix span calculation
y21 Nov 14, 2023
a9d42e6
fix: reduce [`manual_memcpy`] indexing when array length is same to l…
granddaifuku Nov 8, 2023
9aa2330
finish `RegionKind` rename
lcnr Nov 14, 2023
ca8f33e
Auto merge of #11778 - granddaifuku:fix/reduce-indexing-manual_memcpy…
bors Nov 14, 2023
0c42e45
Auto merge of #11791 - Jacherr:iter_over_hash_type, r=Jarcho
bors Nov 14, 2023
9401cf2
Update version attribute for 1.74 lints
xFrednet Nov 14, 2023
cab975c
Changelog for Rust 1.74 :jack_o_lantern:
xFrednet Nov 14, 2023
b3073c5
Change `if_same_then_else` to be a `style` lint
hrxi Nov 14, 2023
a86a570
replace lint with `span_lint_and_then`
Jacherr Nov 15, 2023
11881be
also move `module_style` to `span_lint_x` functions
Jacherr Nov 15, 2023
abf01e4
Auto merge of #11810 - Jacherr:cast-possible-wrap-link, r=Manishearth
bors Nov 15, 2023
19eec0b
disallow `struct_span_lint`
y21 Nov 15, 2023
783b914
Auto merge of #11804 - y21:issue-11803, r=dswij
bors Nov 15, 2023
662ea3f
Auto merge of #11811 - y21:avoid_cx_struct_span_lint, r=Manishearth
bors Nov 15, 2023
7ad3373
Auto merge of #11802 - dswij:issue-11765, r=xFrednet
bors Nov 15, 2023
3ea5bcf
Auto merge of #11809 - hrxi:pr_if_same_then_else_style, r=Alexendoo
bors Nov 15, 2023
406d953
Auto merge of #11806 - xFrednet:changelog-1-74, r=Alexendoo
bors Nov 15, 2023
6fab148
Merge remote-tracking branch 'upstream/master' into rustup
flip1995 Nov 16, 2023
887f5a5
Bump nightly version -> 2023-11-16
flip1995 Nov 16, 2023
6f952fb
Bump Clippy version -> 0.1.76
flip1995 Nov 16, 2023
edb720b
Auto merge of #11823 - flip1995:rustup, r=flip1995
bors Nov 16, 2023
75bdfad
Merge commit 'edb720b199083f4107b858a8761648065bf38d86' into clippyup
flip1995 Nov 16, 2023
2ac2b26
Update Cargo.lock
flip1995 Nov 16, 2023
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
Prev Previous commit
Next Next commit
cargo dev fmt
  • Loading branch information
Jacherr committed Nov 8, 2023
commit 483b109e6e7f741f0827fde46c9263636498b12a
2 changes: 1 addition & 1 deletion clippy_lints/src/types/vec_box.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use clippy_utils::diagnostics::span_lint_and_sugg;
use clippy_utils::{last_path_segment, match_def_path};
use clippy_utils::paths::ALLOCATOR_GLOBAL;
use clippy_utils::source::snippet;
use clippy_utils::{last_path_segment, match_def_path};
use rustc_errors::Applicability;
use rustc_hir::def_id::DefId;
use rustc_hir::{self as hir, GenericArg, QPath, TyKind};
Expand Down
2 changes: 1 addition & 1 deletion clippy_utils/src/paths.rs
Original file line number Diff line number Diff line change
Expand Up @@ -99,4 +99,4 @@ pub const OPTION_UNWRAP: [&str; 4] = ["core", "option", "Option", "unwrap"];
pub const OPTION_EXPECT: [&str; 4] = ["core", "option", "Option", "expect"];
#[expect(clippy::invalid_paths)] // not sure why it thinks this, it works so
pub const BOOL_THEN: [&str; 4] = ["core", "bool", "<impl bool>", "then"];
pub const ALLOCATOR_GLOBAL: [&str; 3] = ["alloc", "alloc", "Global"];
pub const ALLOCATOR_GLOBAL: [&str; 3] = ["alloc", "alloc", "Global"];
6 changes: 3 additions & 3 deletions tests/ui/vec_box_sized.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#![allow(dead_code)]
#![feature(allocator_api)]

use std::alloc::{Layout, AllocError, Allocator};
use std::alloc::{AllocError, Allocator, Layout};
use std::ptr::NonNull;

struct SizedStruct(i32);
Expand All @@ -22,7 +22,7 @@ unsafe impl Allocator for DummyAllocator {

/// The following should trigger the lint
mod should_trigger {
use super::{SizedStruct, DummyAllocator};
use super::{DummyAllocator, SizedStruct};
const C: Vec<Box<i32>> = Vec::new();
static S: Vec<Box<i32>> = Vec::new();

Expand All @@ -46,7 +46,7 @@ mod should_trigger {

/// The following should not trigger the lint
mod should_not_trigger {
use super::{BigStruct, UnsizedStruct, DummyAllocator};
use super::{BigStruct, DummyAllocator, UnsizedStruct};

struct C(Vec<Box<UnsizedStruct>>);
struct D(Vec<Box<BigStruct>>);
Expand Down