Unverified Commit 650523d8 authored by Donny/강동윤's avatar Donny/강동윤 Committed by GitHub

perf(turbopack): Remove needless clone of SWC AST (#79007)

### What?

Part of the memory usage reduction task.

### Why?

We don't need to clone the AST.
parent c1ea3122
......@@ -680,7 +680,6 @@ impl EsmExports {
Ok(CodeGeneration::new(
vec![],
[dynamic_stmt
.clone()
.map(|stmt| CodeGenerationHoistedStmt::new("__turbopack_dynamic__".into(), stmt))]
.into_iter()
.flatten()
......@@ -689,7 +688,7 @@ impl EsmExports {
"__turbopack_esm__".into(),
quote!("$turbopack_esm($getters);" as Stmt,
turbopack_esm: Expr = TURBOPACK_ESM.into(),
getters: Expr = getters.clone()
getters: Expr = getters
),
)],
))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment