test(minifier): simplify ArenaVec builder args to array#24625
Conversation
Merging this PR will not alter performance
Comparing Footnotes
|
69fd3a7 to
3f24355
Compare
702b234 to
6b23ad7
Compare
There was a problem hiding this comment.
Pull request overview
Refactors an oxc_minifier test to use the AST builder’s IntoIn<ArenaVec<_>> conversions, replacing manual ArenaVec construction/pushes with a fixed-size Rust array literal passed directly into ArrayExpression::new.
Changes:
- Replace
ArenaVec::new_in + pushpattern with an inline array literal forArrayExpression::newelements. - Remove the now-unused
ArenaVecimport in the test.
Merge activity
|
Pure refactor. Just shorten code. Replace pattern of creating a `Vec` and pushing to it repeatedly with just passing an array to the AST builder method. This is shorter and more performant - though perf doesn't matter, because it's just in a test.
6b23ad7 to
c06982a
Compare
3f24355 to
f78e096
Compare

Pure refactor. Just shorten code.
Replace pattern of creating a
Vecand pushing to it repeatedly with just passing an array to the AST builder method.This is shorter and more performant - though perf doesn't matter, because it's just in a test.