Avatar for the swc-project user
swc-project
swc
BlogDocsChangelog

Performance History

Latest Results

fix(es/minifier): preserve \in\ operator expression statements (#11246) The \in\ operator always has observable side effects: it triggers the \has\ trap on Proxy objects. A bare \key in proxy\ expression statement must therefore never be dropped by the minifier even when its return value is unused. Two code paths were incorrectly treating \in\ as side-effect-free: 1. \may_have_side_effects()\ in swc_ecma_utils handled all BinExpr arms uniformly, only checking whether the operands have side effects. Added a dedicated \BinOp::In\ arm that unconditionally returns true. 2. \ignore_return_value()\ in the compress optimizer had a catch-all BinExpr arm that decomposed any unrecognised binary expression into a sequence of its operands' side effects. For \SYMBOL in obj\ where both operands are pure declared-variable references this reduced to an empty sequence and the statement was silently dropped. Added a dedicated \BinOp::In\ arm before the catch-all that returns \Some(e.take())\, preserving the full expression. Fixes: https://github.com/swc-project/swc/issues/11246
Kaus1ubh:fix/in-operator-side-effect-11246
1 hour ago
add changeset
Xinkai:xinkai/fix-12430
2 hours ago
chore: Add changeset
refactor/parser-contexts-and-construction
1 day ago
chore: Add changeset
refactor/parser-contexts-and-construction
2 days ago
chore: Add changeset
refactor/parser-contexts-and-construction
2 days ago

Latest Branches

CodSpeed Performance Gauge
0%
fix(es/minifier): preserve \in\ operator expression statements#12432
1 hour ago
85625cb
Kaus1ubh:fix/in-operator-side-effect-11246
CodSpeed Performance Gauge
0%
2 hours ago
2695505
Xinkai:xinkai/fix-12430
CodSpeed Performance Gauge
0%
16 hours ago
8d1e574
LadyBluenotes:fix/object-factory-inline-cost
© 2026 CodSpeed Technology
Home Terms Privacy Docs