@@ -8,7 +8,7 @@ use rustc_attr as attr;
88use rustc_errors:: { ErrorGuaranteed , MultiSpan } ;
99use rustc_hir as hir;
1010use rustc_hir:: def:: { CtorKind , DefKind } ;
11- use rustc_hir:: def_id:: { DefId , LocalDefId , LocalModDefId } ;
11+ use rustc_hir:: def_id:: { DefId , LocalDefId } ;
1212use rustc_hir:: Node ;
1313use rustc_infer:: infer:: outlives:: env:: OutlivesEnvironment ;
1414use rustc_infer:: infer:: { RegionVariableOrigin , TyCtxtInferExt } ;
@@ -443,7 +443,7 @@ fn check_static_linkage(tcx: TyCtxt<'_>, def_id: LocalDefId) {
443443 }
444444}
445445
446- fn check_item_type ( tcx : TyCtxt < ' _ > , def_id : LocalDefId ) {
446+ pub ( crate ) fn check_item_type ( tcx : TyCtxt < ' _ > , def_id : LocalDefId ) {
447447 let _indenter = indenter ( ) ;
448448 match tcx. def_kind ( def_id) {
449449 DefKind :: Static ( ..) => {
@@ -1309,16 +1309,6 @@ pub(super) fn check_type_params_are_used<'tcx>(
13091309 }
13101310}
13111311
1312- pub ( super ) fn check_mod_item_types ( tcx : TyCtxt < ' _ > , module_def_id : LocalModDefId ) {
1313- let module = tcx. hir_module_items ( module_def_id) ;
1314- for id in module. items ( ) {
1315- check_item_type ( tcx, id. owner_id . def_id ) ;
1316- }
1317- if module_def_id == LocalModDefId :: CRATE_DEF_ID {
1318- super :: entry:: check_for_entry_fn ( tcx) ;
1319- }
1320- }
1321-
13221312fn async_opaque_type_cycle_error ( tcx : TyCtxt < ' _ > , span : Span ) -> ErrorGuaranteed {
13231313 struct_span_err ! ( tcx. sess, span, E0733 , "recursion in an `async fn` requires boxing" )
13241314 . span_label ( span, "recursive `async fn`" )
0 commit comments