@@ -14,9 +14,9 @@ use rustc_middle::{bug, span_bug};
14
14
use rustc_span:: { DesugaringKind , Span } ;
15
15
use tracing:: { debug, instrument, trace} ;
16
16
17
- use crate :: build :: ForGuard :: { OutsideGuard , RefWithinGuard } ;
18
- use crate :: build :: expr:: category:: Category ;
19
- use crate :: build :: { BlockAnd , BlockAndExtension , Builder , Capture , CaptureMap } ;
17
+ use crate :: builder :: ForGuard :: { OutsideGuard , RefWithinGuard } ;
18
+ use crate :: builder :: expr:: category:: Category ;
19
+ use crate :: builder :: { BlockAnd , BlockAndExtension , Builder , Capture , CaptureMap } ;
20
20
21
21
/// The "outermost" place that holds this value.
22
22
#[ derive( Copy , Clone , Debug , PartialEq ) ]
@@ -68,7 +68,7 @@ pub(crate) enum PlaceBase {
68
68
/// This is used internally when building a place for an expression like `a.b.c`. The fields `b`
69
69
/// and `c` can be progressively pushed onto the place builder that is created when converting `a`.
70
70
#[ derive( Clone , Debug , PartialEq ) ]
71
- pub ( in crate :: build ) struct PlaceBuilder < ' tcx > {
71
+ pub ( in crate :: builder ) struct PlaceBuilder < ' tcx > {
72
72
base : PlaceBase ,
73
73
projection : Vec < PlaceElem < ' tcx > > ,
74
74
}
@@ -249,7 +249,7 @@ fn strip_prefix<'a, 'tcx>(
249
249
}
250
250
251
251
impl < ' tcx > PlaceBuilder < ' tcx > {
252
- pub ( in crate :: build ) fn to_place ( & self , cx : & Builder < ' _ , ' tcx > ) -> Place < ' tcx > {
252
+ pub ( in crate :: builder ) fn to_place ( & self , cx : & Builder < ' _ , ' tcx > ) -> Place < ' tcx > {
253
253
self . try_to_place ( cx) . unwrap_or_else ( || match self . base {
254
254
PlaceBase :: Local ( local) => span_bug ! (
255
255
cx. local_decls[ local] . source_info. span,
@@ -265,7 +265,7 @@ impl<'tcx> PlaceBuilder<'tcx> {
265
265
}
266
266
267
267
/// Creates a `Place` or returns `None` if an upvar cannot be resolved
268
- pub ( in crate :: build ) fn try_to_place ( & self , cx : & Builder < ' _ , ' tcx > ) -> Option < Place < ' tcx > > {
268
+ pub ( in crate :: builder ) fn try_to_place ( & self , cx : & Builder < ' _ , ' tcx > ) -> Option < Place < ' tcx > > {
269
269
let resolved = self . resolve_upvar ( cx) ;
270
270
let builder = resolved. as_ref ( ) . unwrap_or ( self ) ;
271
271
let PlaceBase :: Local ( local) = builder. base else { return None } ;
@@ -283,7 +283,7 @@ impl<'tcx> PlaceBuilder<'tcx> {
283
283
/// not captured. This can happen because the final mir that will be
284
284
/// generated doesn't require a read for this place. Failures will only
285
285
/// happen inside closures.
286
- pub ( in crate :: build ) fn resolve_upvar (
286
+ pub ( in crate :: builder ) fn resolve_upvar (
287
287
& self ,
288
288
cx : & Builder < ' _ , ' tcx > ,
289
289
) -> Option < PlaceBuilder < ' tcx > > {
0 commit comments