diff --git a/crates/oxc_semantic/src/scoping.rs b/crates/oxc_semantic/src/scoping.rs index 2d9ab11b85372..7cf6096f04026 100644 --- a/crates/oxc_semantic/src/scoping.rs +++ b/crates/oxc_semantic/src/scoping.rs @@ -276,8 +276,7 @@ impl Scoping { }); } else { self.cell.with_dependent_mut(|allocator, cell| { - let mut v = ArenaVec::new_in(allocator); - v.push(span); + let v = ArenaVec::from_array_in([span], allocator); let redeclaration_id = cell.redeclaration_spans.len(); cell.redeclaration_spans.push(v); self.symbol_redeclarations[symbol_id] =