Skip to content

Commit a33faef

Browse files
committed
Auto merge of #135365 - saethlin:box-new, r=<try>
Use Box::new instead of the box_new intrinsic in vec! expansion r? ghost This should perf differently since #135274 landed. Some UI tests are failing locally and seem to indicate a diagnostic regression that I'll fix if this perfs well.
2 parents ce55b20 + fe921ed commit a33faef

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

library/alloc/src/macros.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,7 @@ macro_rules! vec {
4848
);
4949
($($x:expr),+ $(,)?) => (
5050
<[_]>::into_vec(
51-
// Using the intrinsic produces a dramatic improvement in compile
52-
// time when constructing arrays with many elements.
53-
$crate::boxed::box_new([$($x),+])
51+
$crate::boxed::Box::new([$($x),+])
5452
)
5553
);
5654
}

0 commit comments

Comments
 (0)