@@ -537,7 +537,7 @@ impl ExprCompiled {
537537
538538 IrSpanned {
539539 span,
540- node : ExprCompiled :: Builtin2 ( Builtin2 :: Equals , box ( l, r) ) ,
540+ node : ExprCompiled :: Builtin2 ( Builtin2 :: Equals , Box :: new ( ( l, r) ) ) ,
541541 }
542542 }
543543
@@ -553,7 +553,7 @@ impl ExprCompiled {
553553 // Collapse `not not e` to `e` only if `e` is known to produce a boolean.
554554 ExprCompiled :: Builtin1 ( Builtin1 :: Not , e) if e. is_definitely_bool ( ) => ( * e) . clone ( ) ,
555555 _ => IrSpanned {
556- node : ExprCompiled :: Builtin1 ( Builtin1 :: Not , box expr) ,
556+ node : ExprCompiled :: Builtin1 ( Builtin1 :: Not , Box :: new ( expr) ) ,
557557 span,
558558 } ,
559559 }
@@ -581,7 +581,7 @@ impl ExprCompiled {
581581 } else {
582582 let span = l. span . merge ( & r. span ) ;
583583 IrSpanned {
584- node : ExprCompiled :: LogicalBinOp ( op, box ( l, r) ) ,
584+ node : ExprCompiled :: LogicalBinOp ( op, Box :: new ( ( l, r) ) ) ,
585585 span,
586586 }
587587 }
@@ -596,7 +596,7 @@ impl ExprCompiled {
596596 } else {
597597 let span = l. span . merge ( & r. span ) ;
598598 IrSpanned {
599- node : ExprCompiled :: Seq ( box ( l, r) ) ,
599+ node : ExprCompiled :: Seq ( Box :: new ( ( l, r) ) ) ,
600600 span,
601601 }
602602 }
@@ -614,7 +614,7 @@ impl ExprCompiled {
614614 return ExprCompiled :: percent_s_one ( before, r, after, ctx) ;
615615 }
616616 }
617- ExprCompiled :: Builtin2 ( Builtin2 :: Percent , box ( l, r) )
617+ ExprCompiled :: Builtin2 ( Builtin2 :: Percent , Box :: new ( ( l, r) ) )
618618 }
619619
620620 fn percent_s_one (
@@ -632,7 +632,7 @@ impl ExprCompiled {
632632 }
633633 }
634634
635- ExprCompiled :: Builtin1 ( Builtin1 :: PercentSOne ( before, after) , box arg)
635+ ExprCompiled :: Builtin1 ( Builtin1 :: PercentSOne ( before, after) , Box :: new ( arg) )
636636 }
637637
638638 pub ( crate ) fn format_one (
@@ -647,7 +647,7 @@ impl ExprCompiled {
647647 return ExprCompiled :: Value ( value. to_frozen_value ( ) ) ;
648648 }
649649
650- ExprCompiled :: Builtin1 ( Builtin1 :: FormatOne ( before, after) , box arg)
650+ ExprCompiled :: Builtin1 ( Builtin1 :: FormatOne ( before, after) , Box :: new ( arg) )
651651 }
652652
653653 fn add ( l : IrSpanned < ExprCompiled > , r : IrSpanned < ExprCompiled > ) -> ExprCompiled {
@@ -663,7 +663,7 @@ impl ExprCompiled {
663663 . collect ( ) ;
664664 return ExprCompiled :: List ( lr) ;
665665 }
666- ExprCompiled :: Builtin2 ( Builtin2 :: Add , box ( l, r) )
666+ ExprCompiled :: Builtin2 ( Builtin2 :: Add , Box :: new ( ( l, r) ) )
667667 }
668668
669669 pub ( crate ) fn bin_op (
@@ -688,7 +688,7 @@ impl ExprCompiled {
688688 Builtin2 :: Add => ExprCompiled :: add ( l, r) ,
689689 Builtin2 :: Equals => ExprCompiled :: equals ( l, r) . node ,
690690 Builtin2 :: ArrayIndex => ExprCompiled :: array_indirection ( l, r, ctx) ,
691- bin_op => ExprCompiled :: Builtin2 ( bin_op, box ( l, r) ) ,
691+ bin_op => ExprCompiled :: Builtin2 ( bin_op, Box :: new ( ( l, r) ) ) ,
692692 }
693693 }
694694
@@ -715,7 +715,7 @@ impl ExprCompiled {
715715 } ;
716716 let span = cond. span . merge ( & t. span ) . merge ( & f. span ) ;
717717 IrSpanned {
718- node : ExprCompiled :: If ( box ( cond, t, f) ) ,
718+ node : ExprCompiled :: If ( Box :: new ( ( cond, t, f) ) ) ,
719719 span,
720720 }
721721 }
@@ -746,7 +746,7 @@ impl ExprCompiled {
746746 Builtin1 :: Dot ( field) => ExprCompiled :: dot ( expr, field, ctx) ,
747747 Builtin1 :: TypeIs ( t) => ExprCompiled :: type_is ( expr, * t) ,
748748 Builtin1 :: Not => ExprCompiled :: not ( span, expr) . node ,
749- op => ExprCompiled :: Builtin1 ( op. clone ( ) , box expr) ,
749+ op => ExprCompiled :: Builtin1 ( op. clone ( ) , Box :: new ( expr) ) ,
750750 }
751751 }
752752
@@ -813,7 +813,7 @@ impl ExprCompiled {
813813 if clauses. is_nop ( ) {
814814 ExprCompiled :: Dict ( Vec :: new ( ) )
815815 } else {
816- ExprCompiled :: Compr ( ComprCompiled :: Dict ( box ( k, v) , clauses) )
816+ ExprCompiled :: Compr ( ComprCompiled :: Dict ( Box :: new ( ( k, v) ) , clauses) )
817817 }
818818 }
819819 }
@@ -857,7 +857,7 @@ impl ExprCompiled {
857857 }
858858 }
859859
860- ExprCompiled :: Builtin1 ( Builtin1 :: Dot ( field. clone ( ) ) , box object)
860+ ExprCompiled :: Builtin1 ( Builtin1 :: Dot ( field. clone ( ) ) , Box :: new ( object) )
861861 }
862862
863863 fn slice (
@@ -885,7 +885,7 @@ impl ExprCompiled {
885885 }
886886 }
887887 }
888- ExprCompiled :: Slice ( box ( array, start, stop, step) )
888+ ExprCompiled :: Slice ( Box :: new ( ( array, start, stop, step) ) )
889889 }
890890
891891 pub ( crate ) fn array_indirection (
@@ -901,7 +901,7 @@ impl ExprCompiled {
901901 }
902902 }
903903 }
904- ExprCompiled :: Builtin2 ( Builtin2 :: ArrayIndex , box ( array, index) )
904+ ExprCompiled :: Builtin2 ( Builtin2 :: ArrayIndex , Box :: new ( ( array, index) ) )
905905 }
906906
907907 pub ( crate ) fn typ ( span : FrozenFileSpan , v : IrSpanned < ExprCompiled > ) -> ExprCompiled {
@@ -923,7 +923,7 @@ impl ExprCompiled {
923923 {
924924 ExprCompiled :: Value ( StarlarkBool :: get_type_value_static ( ) . to_frozen_value ( ) )
925925 }
926- _ => ExprCompiled :: Call ( box IrSpanned {
926+ _ => ExprCompiled :: Call ( Box :: new ( IrSpanned {
927927 span,
928928 node : CallCompiled {
929929 fun : IrSpanned {
@@ -935,7 +935,7 @@ impl ExprCompiled {
935935 ..ArgsCompiledValue :: default ( )
936936 } ,
937937 } ,
938- } ) ,
938+ } ) ) ,
939939 }
940940 }
941941
@@ -945,7 +945,7 @@ impl ExprCompiled {
945945 v. to_value ( ) . get_type ( ) == t. as_str ( ) ,
946946 ) ) ;
947947 }
948- ExprCompiled :: Builtin1 ( Builtin1 :: TypeIs ( t) , box v )
948+ ExprCompiled :: Builtin1 ( Builtin1 :: TypeIs ( t) , Box :: new ( v ) )
949949 }
950950
951951 pub ( crate ) fn len ( span : FrozenFileSpan , arg : IrSpanned < ExprCompiled > ) -> ExprCompiled {
@@ -954,7 +954,7 @@ impl ExprCompiled {
954954 return ExprCompiled :: Value ( FrozenValue :: new_int ( len) ) ;
955955 }
956956 }
957- ExprCompiled :: Call ( box IrSpanned {
957+ ExprCompiled :: Call ( Box :: new ( IrSpanned {
958958 span,
959959 node : CallCompiled {
960960 fun : IrSpanned {
@@ -966,7 +966,7 @@ impl ExprCompiled {
966966 ..ArgsCompiledValue :: default ( )
967967 } ,
968968 } ,
969- } )
969+ } ) )
970970 }
971971}
972972
0 commit comments