@@ -116,7 +116,7 @@ pub fn provide(providers: &mut Providers) {
116116/// `ItemCtxt` is parameterized by a `DefId` that it uses to satisfy
117117/// `get_type_parameter_bounds` requests, drawing the information from
118118/// the AST (`hir::Generics`), recursively.
119- struct ItemCtxt < ' a , ' tcx : ' a > {
119+ pub struct ItemCtxt < ' a , ' tcx : ' a > {
120120 tcx : TyCtxt < ' a , ' tcx , ' tcx > ,
121121 item_def_id : DefId ,
122122}
@@ -180,7 +180,7 @@ impl<'a, 'tcx> Visitor<'tcx> for CollectItemTypesVisitor<'a, 'tcx> {
180180// Utility types and common code for the above passes.
181181
182182impl < ' a , ' tcx > ItemCtxt < ' a , ' tcx > {
183- fn new ( tcx : TyCtxt < ' a , ' tcx , ' tcx > , item_def_id : DefId )
183+ pub fn new ( tcx : TyCtxt < ' a , ' tcx , ' tcx > , item_def_id : DefId )
184184 -> ItemCtxt < ' a , ' tcx > {
185185 ItemCtxt {
186186 tcx : tcx,
@@ -190,7 +190,7 @@ impl<'a, 'tcx> ItemCtxt<'a, 'tcx> {
190190}
191191
192192impl < ' a , ' tcx > ItemCtxt < ' a , ' tcx > {
193- fn to_ty ( & self , ast_ty : & hir:: Ty ) -> Ty < ' tcx > {
193+ pub fn to_ty ( & self , ast_ty : & hir:: Ty ) -> Ty < ' tcx > {
194194 AstConv :: ast_ty_to_ty ( self , ast_ty)
195195 }
196196}
0 commit comments