From 71e02a01a14b00c8bbc4a679d258c07270bfe226 Mon Sep 17 00:00:00 2001 From: y21 <30553356+y21@users.noreply.github.com> Date: Fri, 5 Apr 2024 00:17:27 +0200 Subject: [PATCH] use `Lrc` instead of the aliased type `Arc` directly --- clippy_lints/src/attrs/mixed_attributes_style.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/clippy_lints/src/attrs/mixed_attributes_style.rs b/clippy_lints/src/attrs/mixed_attributes_style.rs index 75a3d7a9a..5d2ea36b3 100644 --- a/clippy_lints/src/attrs/mixed_attributes_style.rs +++ b/clippy_lints/src/attrs/mixed_attributes_style.rs @@ -2,10 +2,10 @@ use super::MIXED_ATTRIBUTES_STYLE; use clippy_utils::diagnostics::span_lint; use rustc_ast::{AttrKind, AttrStyle, Attribute}; use rustc_data_structures::fx::FxHashSet; +use rustc_data_structures::sync::Lrc; use rustc_lint::{LateContext, LintContext}; use rustc_span::source_map::SourceMap; use rustc_span::{SourceFile, Span, Symbol}; -use std::sync::Arc; #[derive(Hash, PartialEq, Eq)] enum SimpleAttrKind { @@ -79,7 +79,7 @@ fn lint_mixed_attrs(cx: &LateContext<'_>, attrs: &[Attribute]) { ); } -fn attr_in_same_src_as_item(source_map: &SourceMap, item_src: &Arc, attr_span: Span) -> bool { +fn attr_in_same_src_as_item(source_map: &SourceMap, item_src: &Lrc, attr_span: Span) -> bool { let attr_src = source_map.lookup_source_file(attr_span.lo()); - Arc::ptr_eq(item_src, &attr_src) + Lrc::ptr_eq(item_src, &attr_src) }