Skip to content

Commit e5ce6d1

Browse files
committed
rustc_typeck to rustc_hir_analysis
1 parent 06568fd commit e5ce6d1

25 files changed

+31
-31
lines changed

clippy_lints/src/default_union_representation.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use rustc_lint::{LateContext, LateLintPass};
44
use rustc_middle::ty::layout::LayoutOf;
55
use rustc_session::{declare_lint_pass, declare_tool_lint};
66
use rustc_span::sym;
7-
use rustc_typeck::hir_ty_to_ty;
7+
use rustc_hir_analysis::hir_ty_to_ty;
88

99
declare_clippy_lint! {
1010
/// ### What it does

clippy_lints/src/escape.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ use rustc_session::{declare_tool_lint, impl_lint_pass};
1010
use rustc_span::source_map::Span;
1111
use rustc_span::symbol::kw;
1212
use rustc_target::spec::abi::Abi;
13-
use rustc_typeck::expr_use_visitor::{Delegate, ExprUseVisitor, PlaceBase, PlaceWithHirId};
13+
use rustc_hir_analysis::expr_use_visitor::{Delegate, ExprUseVisitor, PlaceBase, PlaceWithHirId};
1414

1515
#[derive(Copy, Clone)]
1616
pub struct BoxedLocal {
@@ -177,7 +177,7 @@ impl<'a, 'tcx> Delegate<'tcx> for EscapeDelegate<'a, 'tcx> {
177177
}
178178
}
179179

180-
fn fake_read(&mut self, _: &rustc_typeck::expr_use_visitor::PlaceWithHirId<'tcx>, _: FakeReadCause, _: HirId) {}
180+
fn fake_read(&mut self, _: &rustc_hir_analysis::expr_use_visitor::PlaceWithHirId<'tcx>, _: FakeReadCause, _: HirId) {}
181181
}
182182

183183
impl<'a, 'tcx> EscapeDelegate<'a, 'tcx> {

clippy_lints/src/implicit_hasher.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ use rustc_middle::ty::{Ty, TypeckResults};
1212
use rustc_session::{declare_lint_pass, declare_tool_lint};
1313
use rustc_span::source_map::Span;
1414
use rustc_span::symbol::sym;
15-
use rustc_typeck::hir_ty_to_ty;
15+
use rustc_hir_analysis::hir_ty_to_ty;
1616

1717
use if_chain::if_chain;
1818

clippy_lints/src/large_const_arrays.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ use rustc_middle::ty::layout::LayoutOf;
77
use rustc_middle::ty::{self, ConstKind};
88
use rustc_session::{declare_tool_lint, impl_lint_pass};
99
use rustc_span::{BytePos, Pos, Span};
10-
use rustc_typeck::hir_ty_to_ty;
10+
use rustc_hir_analysis::hir_ty_to_ty;
1111

1212
declare_clippy_lint! {
1313
/// ### What it does

clippy_lints/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ extern crate rustc_session;
4343
extern crate rustc_span;
4444
extern crate rustc_target;
4545
extern crate rustc_trait_selection;
46-
extern crate rustc_typeck;
46+
extern crate rustc_hir_analysis;
4747

4848
#[macro_use]
4949
extern crate clippy_utils;

clippy_lints/src/loops/mut_range_bound.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ use rustc_infer::infer::TyCtxtInferExt;
88
use rustc_lint::LateContext;
99
use rustc_middle::{mir::FakeReadCause, ty};
1010
use rustc_span::source_map::Span;
11-
use rustc_typeck::expr_use_visitor::{Delegate, ExprUseVisitor, PlaceBase, PlaceWithHirId};
11+
use rustc_hir_analysis::expr_use_visitor::{Delegate, ExprUseVisitor, PlaceBase, PlaceWithHirId};
1212

1313
pub(super) fn check(cx: &LateContext<'_>, arg: &Expr<'_>, body: &Expr<'_>) {
1414
if_chain! {
@@ -114,7 +114,7 @@ impl<'tcx> Delegate<'tcx> for MutatePairDelegate<'_, 'tcx> {
114114
}
115115
}
116116

117-
fn fake_read(&mut self, _: &rustc_typeck::expr_use_visitor::PlaceWithHirId<'tcx>, _: FakeReadCause, _: HirId) {}
117+
fn fake_read(&mut self, _: &rustc_hir_analysis::expr_use_visitor::PlaceWithHirId<'tcx>, _: FakeReadCause, _: HirId) {}
118118
}
119119

120120
impl MutatePairDelegate<'_, '_> {

clippy_lints/src/loops/utils.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ use rustc_middle::hir::nested_filter;
1010
use rustc_middle::ty::{self, Ty};
1111
use rustc_span::source_map::Spanned;
1212
use rustc_span::symbol::{sym, Symbol};
13-
use rustc_typeck::hir_ty_to_ty;
13+
use rustc_hir_analysis::hir_ty_to_ty;
1414
use std::iter::Iterator;
1515

1616
#[derive(Debug, PartialEq, Eq)]

clippy_lints/src/matches/needless_match.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use rustc_hir::LangItem::OptionNone;
1111
use rustc_hir::{Arm, BindingAnnotation, ByRef, Expr, ExprKind, FnRetTy, Guard, Node, Pat, PatKind, Path, QPath};
1212
use rustc_lint::LateContext;
1313
use rustc_span::sym;
14-
use rustc_typeck::hir_ty_to_ty;
14+
use rustc_hir_analysis::hir_ty_to_ty;
1515

1616
pub(crate) fn check_match(cx: &LateContext<'_>, ex: &Expr<'_>, arms: &[Arm<'_>], expr: &Expr<'_>) {
1717
if arms.len() > 1 && expr_ty_matches_p_ty(cx, ex, expr) && check_all_arms(cx, ex, arms) {

clippy_lints/src/methods/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ use rustc_middle::ty::{self, TraitRef, Ty};
115115
use rustc_semver::RustcVersion;
116116
use rustc_session::{declare_tool_lint, impl_lint_pass};
117117
use rustc_span::{sym, Span};
118-
use rustc_typeck::hir_ty_to_ty;
118+
use rustc_hir_analysis::hir_ty_to_ty;
119119

120120
declare_clippy_lint! {
121121
/// ### What it does

clippy_lints/src/methods/unnecessary_to_owned.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ use rustc_middle::ty::{self, ParamTy, PredicateKind, ProjectionPredicate, TraitP
1818
use rustc_semver::RustcVersion;
1919
use rustc_span::{sym, Symbol};
2020
use rustc_trait_selection::traits::{query::evaluate_obligation::InferCtxtExt as _, Obligation, ObligationCause};
21-
use rustc_typeck::check::{FnCtxt, Inherited};
21+
use rustc_hir_analysis::check::{FnCtxt, Inherited};
2222
use std::cmp::max;
2323

2424
use super::UNNECESSARY_TO_OWNED;

0 commit comments

Comments
 (0)