Skip to content

Commit 44c1ef8

Browse files
committed
Use () for inherent_impls.
1 parent b03b747 commit 44c1ef8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

clippy_lints/src/inherent_impl.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
use clippy_utils::diagnostics::span_lint_and_then;
44
use clippy_utils::in_macro;
55
use rustc_hir::def_id::DefIdMap;
6-
use rustc_hir::{def_id, Crate, Impl, Item, ItemKind};
6+
use rustc_hir::{Crate, Impl, Item, ItemKind};
77
use rustc_lint::{LateContext, LateLintPass};
88
use rustc_session::{declare_tool_lint, impl_lint_pass};
99
use rustc_span::Span;
@@ -68,7 +68,7 @@ impl<'tcx> LateLintPass<'tcx> for MultipleInherentImpl {
6868
fn check_crate_post(&mut self, cx: &LateContext<'tcx>, krate: &'tcx Crate<'_>) {
6969
if !krate.items.is_empty() {
7070
// Retrieve all inherent implementations from the crate, grouped by type
71-
for impls in cx.tcx.crate_inherent_impls(def_id::LOCAL_CRATE).inherent_impls.values() {
71+
for impls in cx.tcx.crate_inherent_impls(()).inherent_impls.values() {
7272
// Filter out implementations that have generic params (type or lifetime)
7373
let mut impl_spans = impls.iter().filter_map(|impl_def| self.impls.get(impl_def));
7474
if let Some(initial_span) = impl_spans.next() {

0 commit comments

Comments
 (0)