@@ -432,7 +432,7 @@ pub enum MethodOrigin<'tcx> {
432432 // fully statically resolved method
433433 MethodStatic ( ast:: DefId ) ,
434434
435- // fully statically resolved unboxed closure invocation
435+ // fully statically resolved closure invocation
436436 MethodStaticClosure ( ast:: DefId ) ,
437437
438438 // method invoked on a type parameter with a bounded trait
@@ -565,7 +565,7 @@ pub enum vtable_origin<'tcx> {
565565 vtable_param( param_index , uint ) ,
566566
567567 /*
568- Vtable automatically generated for an unboxed closure. The def ID is the
568+ Vtable automatically generated for a closure. The def ID is the
569569 ID of the closure expression.
570570 */
571571 vtable_closure( ast:: DefId ) ,
@@ -785,8 +785,8 @@ pub struct ctxt<'tcx> {
785785
786786 pub dependency_formats : RefCell < dependency_format:: Dependencies > ,
787787
788- /// Records the type of each unboxed closure. The def ID is the ID of the
789- /// expression defining the unboxed closure.
788+ /// Records the type of each closure. The def ID is the ID of the
789+ /// expression defining the closure.
790790 pub closures : RefCell < DefIdMap < Closure < ' tcx > > > ,
791791
792792 pub node_lint_levels : RefCell < FnvHashMap < ( ast:: NodeId , lint:: LintId ) ,
@@ -2262,12 +2262,12 @@ pub struct ItemSubsts<'tcx> {
22622262 pub substs : Substs < ' tcx > ,
22632263}
22642264
2265- /// Records information about each unboxed closure.
2265+ /// Records information about each closure.
22662266#[ derive( Clone ) ]
22672267pub struct Closure < ' tcx > {
2268- /// The type of the unboxed closure.
2268+ /// The type of the closure.
22692269 pub closure_type : ClosureTy < ' tcx > ,
2270- /// The kind of unboxed closure this is.
2270+ /// The kind of closure this is.
22712271 pub kind : ClosureKind ,
22722272}
22732273
@@ -3416,8 +3416,7 @@ pub fn type_contents<'tcx>(cx: &ctxt<'tcx>, ty: Ty<'tcx>) -> TypeContents {
34163416 }
34173417
34183418 ty_closure( did, r, substs) => {
3419- // FIXME(#14449): `borrowed_contents` below assumes `&mut`
3420- // unboxed closure.
3419+ // FIXME(#14449): `borrowed_contents` below assumes `&mut` closure.
34213420 let param_env = ty:: empty_parameter_environment ( cx) ;
34223421 let upvars = closure_upvars ( & param_env, did, substs) . unwrap ( ) ;
34233422 TypeContents :: union ( upvars. as_slice ( ) ,
@@ -3685,7 +3684,7 @@ pub fn is_instantiable<'tcx>(cx: &ctxt<'tcx>, r_ty: Ty<'tcx>) -> bool {
36853684 ty_infer( _) |
36863685 ty_closure( ..) => {
36873686 // this check is run on type definitions, so we don't expect to see
3688- // inference by-products or unboxed closure types
3687+ // inference by-products or closure types
36893688 cx. sess . bug ( format ! ( "requires check invoked on inapplicable type: {:?}" ,
36903689 ty) . as_slice ( ) )
36913690 }
@@ -3778,8 +3777,8 @@ pub fn is_type_representable<'tcx>(cx: &ctxt<'tcx>, sp: Span, ty: Ty<'tcx>)
37783777 find_nonrepresentable ( cx, sp, seen, iter)
37793778 }
37803779 ty_closure( ..) => {
3781- // this check is run on type definitions, so we don't expect to see
3782- // unboxed closure types
3780+ // this check is run on type definitions, so we don't expect
3781+ // to see closure types
37833782 cx. sess . bug ( format ! ( "requires check invoked on inapplicable type: {:?}" ,
37843783 ty) . as_slice ( ) )
37853784 }
0 commit comments