Skip to content

Commit c9f25c4

Browse files
committed
Auto merge of #139996 - matthiaskrgr:rollup-0nka2hw, r=matthiaskrgr
Rollup of 7 pull requests Successful merges: - #138528 (deref patterns: implement implicit deref patterns) - #139393 (rustdoc-json: Output target feature information) - #139553 (sync::mpsc: prevent double free on `Drop`) - #139615 (Remove `name_or_empty`) - #139853 (Disable combining LLD with external llvm-config) - #139913 (rustdoc/clean: Fix lowering of fn params (fixes correctness & HIR vs. middle parity regressions)) - #139942 (Ignore aix for tests/ui/erros/pic-linker.rs) r? `@ghost` `@rustbot` modify labels: rollup
2 parents 6a4f71b + de198df commit c9f25c4

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

clippy_lints/src/pattern_type_mismatch.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ fn find_first_mismatch(cx: &LateContext<'_>, pat: &Pat<'_>) -> Option<(Span, Mut
179179
};
180180
if let Some(adjustments) = cx.typeck_results().pat_adjustments().get(adjust_pat.hir_id) {
181181
if let [first, ..] = **adjustments {
182-
if let ty::Ref(.., mutability) = *first.kind() {
182+
if let ty::Ref(.., mutability) = *first.source.kind() {
183183
let level = if p.hir_id == pat.hir_id {
184184
Level::Top
185185
} else {

clippy_utils/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2363,14 +2363,14 @@ pub fn is_no_std_crate(cx: &LateContext<'_>) -> bool {
23632363
cx.tcx
23642364
.hir_attrs(hir::CRATE_HIR_ID)
23652365
.iter()
2366-
.any(|attr| attr.name_or_empty() == sym::no_std)
2366+
.any(|attr| attr.has_name(sym::no_std))
23672367
}
23682368

23692369
pub fn is_no_core_crate(cx: &LateContext<'_>) -> bool {
23702370
cx.tcx
23712371
.hir_attrs(hir::CRATE_HIR_ID)
23722372
.iter()
2373-
.any(|attr| attr.name_or_empty() == sym::no_core)
2373+
.any(|attr| attr.has_name(sym::no_core))
23742374
}
23752375

23762376
/// Check if parent of a hir node is a trait implementation block.

0 commit comments

Comments
 (0)