Skip to content

Commit c546803

Browse files
committed
Rename module astconv to hir_ty_lowering
Split from the main renaming commit to make git generate a proper diff for ease of reviewing.
1 parent 4d4711a commit c546803

File tree

20 files changed

+28
-24
lines changed

20 files changed

+28
-24
lines changed

compiler/rustc_hir_analysis/src/collect.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,9 @@ use std::cell::Cell;
4040
use std::iter;
4141
use std::ops::Bound;
4242

43-
use crate::astconv::HirTyLowerer;
4443
use crate::check::intrinsic::intrinsic_operation_unsafety;
4544
use crate::errors;
45+
use crate::hir_ty_lowering::HirTyLowerer;
4646
pub use type_of::test_opaque_hidden_types;
4747

4848
mod generics_of;

compiler/rustc_hir_analysis/src/collect/item_bounds.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use super::ItemCtxt;
2-
use crate::astconv::{HirTyLowerer, PredicateFilter};
2+
use crate::hir_ty_lowering::{HirTyLowerer, PredicateFilter};
33
use rustc_hir as hir;
44
use rustc_infer::traits::util;
55
use rustc_middle::ty::GenericArgs;

compiler/rustc_hir_analysis/src/collect/predicates_of.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
use crate::astconv::{HirTyLowerer, OnlySelfBounds, PredicateFilter};
21
use crate::bounds::Bounds;
32
use crate::collect::ItemCtxt;
43
use crate::constrained_generic_params as cgp;
4+
use crate::hir_ty_lowering::{HirTyLowerer, OnlySelfBounds, PredicateFilter};
55
use hir::{HirId, Node};
66
use rustc_data_structures::fx::FxIndexSet;
77
use rustc_hir as hir;

compiler/rustc_hir_analysis/src/collect/type_of.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ fn anon_const_type_of<'tcx>(tcx: TyCtxt<'tcx>, def_id: LocalDefId) -> Ty<'tcx> {
109109
.0
110110
.def_id;
111111
let item_ctxt =
112-
&ItemCtxt::new(tcx, item_def_id) as &dyn crate::astconv::HirTyLowerer<'_>;
112+
&ItemCtxt::new(tcx, item_def_id) as &dyn crate::hir_ty_lowering::HirTyLowerer<'_>;
113113
let ty = item_ctxt.lower_ty(hir_ty);
114114

115115
// Iterate through the generics of the projection to find the one that corresponds to

compiler/rustc_hir_analysis/src/astconv/bounds.rs renamed to compiler/rustc_hir_analysis/src/hir_ty_lowering/bounds.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ use rustc_span::{ErrorGuaranteed, Span};
99
use rustc_trait_selection::traits;
1010
use smallvec::SmallVec;
1111

12-
use crate::astconv::{HirTyLowerer, OnlySelfBounds, PredicateFilter};
1312
use crate::bounds::Bounds;
1413
use crate::errors;
14+
use crate::hir_ty_lowering::{HirTyLowerer, OnlySelfBounds, PredicateFilter};
1515

1616
impl<'tcx> dyn HirTyLowerer<'tcx> + '_ {
1717
/// Add a `Sized` bound to the `bounds` if appropriate.

compiler/rustc_hir_analysis/src/astconv/errors.rs renamed to compiler/rustc_hir_analysis/src/hir_ty_lowering/errors.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
use crate::astconv::HirTyLowerer;
21
use crate::errors::{
32
self, AssocTypeBindingNotAllowed, ManualImplementation, MissingTypeParams,
43
ParenthesizedFnTraitExpansion,
54
};
65
use crate::fluent_generated as fluent;
6+
use crate::hir_ty_lowering::HirTyLowerer;
77
use crate::traits::error_reporting::report_object_safety_error;
88
use rustc_data_structures::fx::{FxIndexMap, FxIndexSet};
99
use rustc_data_structures::sorted_map::SortedMap;

compiler/rustc_hir_analysis/src/astconv/generics.rs renamed to compiler/rustc_hir_analysis/src/hir_ty_lowering/generics.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use super::IsMethodCall;
2-
use crate::astconv::{
2+
use crate::hir_ty_lowering::{
33
errors::prohibit_assoc_item_binding, ExplicitLateBound, GenericArgCountMismatch,
44
GenericArgCountResult, GenericArgPosition, GenericArgsLowerer,
55
};

compiler/rustc_hir_analysis/src/astconv/mod.rs renamed to compiler/rustc_hir_analysis/src/hir_ty_lowering/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ pub mod generics;
1919
mod lint;
2020
mod object_safety;
2121

22-
use crate::astconv::errors::prohibit_assoc_item_binding;
23-
use crate::astconv::generics::{check_generic_arg_count, lower_generic_args};
2422
use crate::bounds::Bounds;
2523
use crate::collect::HirPlaceholderCollector;
2624
use crate::errors::AmbiguousLifetimeBound;
25+
use crate::hir_ty_lowering::errors::prohibit_assoc_item_binding;
26+
use crate::hir_ty_lowering::generics::{check_generic_arg_count, lower_generic_args};
2727
use crate::middle::resolve_bound_vars as rbv;
2828
use crate::require_c_abi_if_c_variadic;
2929
use rustc_ast::TraitObjectSyntax;

compiler/rustc_hir_analysis/src/astconv/object_safety.rs renamed to compiler/rustc_hir_analysis/src/hir_ty_lowering/object_safety.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
use crate::astconv::{GenericArgCountMismatch, GenericArgCountResult, OnlySelfBounds};
21
use crate::bounds::Bounds;
32
use crate::errors::TraitObjectDeclaredWithNoTraits;
3+
use crate::hir_ty_lowering::{GenericArgCountMismatch, GenericArgCountResult, OnlySelfBounds};
44
use rustc_data_structures::fx::{FxHashSet, FxIndexMap, FxIndexSet};
55
use rustc_errors::{codes::*, struct_span_code_err};
66
use rustc_hir as hir;

0 commit comments

Comments
 (0)