Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit dca15fd

Browse files
committed
rename create_raw_ty -> handle_raw_ty
1 parent 8afd3c4 commit dca15fd

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

compiler/rustc_hir_typeck/src/fn_ctxt/_impl.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -369,14 +369,14 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
369369
}
370370
}
371371

372-
pub fn create_raw_ty(&self, span: Span, ty: Ty<'tcx>) -> RawTy<'tcx> {
372+
pub fn handle_raw_ty(&self, span: Span, ty: Ty<'tcx>) -> RawTy<'tcx> {
373373
RawTy { raw: ty, normalized: self.normalize(span, ty) }
374374
}
375375

376376
pub fn to_ty(&self, ast_t: &hir::Ty<'_>) -> RawTy<'tcx> {
377377
let t = <dyn AstConv<'_>>::ast_ty_to_ty(self, ast_t);
378378
self.register_wf_obligation(t.into(), ast_t.span, traits::WellFormed(None));
379-
self.create_raw_ty(ast_t.span, t)
379+
self.handle_raw_ty(ast_t.span, t)
380380
}
381381

382382
pub fn to_ty_saving_user_provided_ty(&self, ast_ty: &hir::Ty<'_>) -> Ty<'tcx> {
@@ -767,7 +767,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
767767
// We manually call `register_wf_obligation` in the success path
768768
// below.
769769
let ty = <dyn AstConv<'_>>::ast_ty_to_ty_in_path(self, qself);
770-
(self.create_raw_ty(span, ty), qself, segment)
770+
(self.handle_raw_ty(span, ty), qself, segment)
771771
}
772772
QPath::LangItem(..) => {
773773
bug!("`resolve_ty_and_res_fully_qualified_call` called on `LangItem`")

compiler/rustc_hir_typeck/src/fn_ctxt/checks.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1683,7 +1683,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
16831683
QPath::Resolved(ref maybe_qself, ref path) => {
16841684
let self_ty = maybe_qself.as_ref().map(|qself| self.to_ty(qself).raw);
16851685
let ty = <dyn AstConv<'_>>::res_to_ty(self, self_ty, path, true);
1686-
(path.res, self.create_raw_ty(path_span, ty))
1686+
(path.res, self.handle_raw_ty(path_span, ty))
16871687
}
16881688
QPath::TypeRelative(ref qself, ref segment) => {
16891689
let ty = self.to_ty(qself);
@@ -1692,7 +1692,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
16921692
self, hir_id, path_span, ty.raw, qself, segment, true,
16931693
);
16941694
let ty = result.map(|(ty, _, _)| ty).unwrap_or_else(|_| self.tcx().ty_error());
1695-
let ty = self.create_raw_ty(path_span, ty);
1695+
let ty = self.handle_raw_ty(path_span, ty);
16961696
let result = result.map(|(_, kind, def_id)| (kind, def_id));
16971697

16981698
// Write back the new resolution.
@@ -1702,7 +1702,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
17021702
}
17031703
QPath::LangItem(lang_item, span, id) => {
17041704
let (res, ty) = self.resolve_lang_item_path(lang_item, span, hir_id, id);
1705-
(res, self.create_raw_ty(path_span, ty))
1705+
(res, self.handle_raw_ty(path_span, ty))
17061706
}
17071707
}
17081708
}

0 commit comments

Comments
 (0)