diff --git a/crates/oxc_transformer/src/es2022/class_properties/supers.rs b/crates/oxc_transformer/src/es2022/class_properties/supers.rs index 95be2a1ecda21..1f57ffb7e21d6 100644 --- a/crates/oxc_transformer/src/es2022/class_properties/supers.rs +++ b/crates/oxc_transformer/src/es2022/class_properties/supers.rs @@ -98,9 +98,8 @@ impl<'a, 'ctx> ClassProperties<'a, 'ctx> { arguments: &mut ArenaVec<'a, Argument<'a>>, ctx: &mut TraverseCtx<'a>, ) { - let owned_arguments = ctx.ast.move_vec(arguments); - let elements = - ctx.ast.vec_from_iter(owned_arguments.into_iter().map(ArrayExpressionElement::from)); + let elements = arguments.drain(..).map(ArrayExpressionElement::from); + let elements = ctx.ast.vec_from_iter(elements); let array = ctx.ast.expression_array(SPAN, elements, None); arguments.push(Argument::from(array)); }