Repository navigation
Commit 5ba5dba
authored
fix(javascript): keep an
* fix(javascript): keep an `arguments` read before a write to its parameter in the minifier
In a sloppy function with simple parameters `arguments[i]` aliases the
parameter, but collapse_vars moved `t = arguments[0]` past `x = {}`, so
the read saw the new value (terser#768, terser#1165).
Claude-Session: https://claude.ai/code/session_01UgQAw35dRJd9GKMF9p5CcQ
* test(javascript): cover more `arguments` aliasing in the minifier
Several parameters, a second parameter, a computed index and a read in an
arrow, which terser misprints; and reads it already writes right, which
the correct phase leaves as they are.
Claude-Session: https://claude.ai/code/session_01UgQAw35dRJd9GKMF9p5CcQarguments read before a write to its parameter in the minifier (#22599)1 parent 37538ee commit 5ba5dba
2 files changed
Lines changed: 82 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17073 | 17073 | | |
17074 | 17074 | | |
17075 | 17075 | | |
| 17076 | + | |
| 17077 | + | |
| 17078 | + | |
| 17079 | + | |
| 17080 | + | |
| 17081 | + | |
| 17082 | + | |
| 17083 | + | |
| 17084 | + | |
| 17085 | + | |
| 17086 | + | |
| 17087 | + | |
| 17088 | + | |
| 17089 | + | |
17076 | 17090 | | |
17077 | 17091 | | |
17078 | 17092 | | |
| |||
26391 | 26405 | | |
26392 | 26406 | | |
26393 | 26407 | | |
| 26408 | + | |
26394 | 26409 | | |
26395 | 26410 | | |
26396 | 26411 | | |
| |||
26410 | 26425 | | |
26411 | 26426 | | |
26412 | 26427 | | |
| 26428 | + | |
26413 | 26429 | | |
26414 | 26430 | | |
26415 | 26431 | | |
| |||
27999 | 28015 | | |
28000 | 28016 | | |
28001 | 28017 | | |
| 28018 | + | |
| 28019 | + | |
| 28020 | + | |
| 28021 | + | |
| 28022 | + | |
| 28023 | + | |
| 28024 | + | |
| 28025 | + | |
| 28026 | + | |
| 28027 | + | |
| 28028 | + | |
| 28029 | + | |
| 28030 | + | |
28002 | 28031 | | |
28003 | 28032 | | |
28004 | 28033 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1254 | 1254 | | |
1255 | 1255 | | |
1256 | 1256 | | |
| 1257 | + | |
| 1258 | + | |
| 1259 | + | |
| 1260 | + | |
| 1261 | + | |
| 1262 | + | |
| 1263 | + | |
| 1264 | + | |
| 1265 | + | |
| 1266 | + | |
| 1267 | + | |
| 1268 | + | |
| 1269 | + | |
| 1270 | + | |
1257 | 1271 | | |
1258 | 1272 | | |
1259 | 1273 | | |
| |||
1357 | 1371 | | |
1358 | 1372 | | |
1359 | 1373 | | |
| 1374 | + | |
| 1375 | + | |
| 1376 | + | |
| 1377 | + | |
| 1378 | + | |
| 1379 | + | |
| 1380 | + | |
| 1381 | + | |
| 1382 | + | |
| 1383 | + | |
| 1384 | + | |
| 1385 | + | |
| 1386 | + | |
| 1387 | + | |
| 1388 | + | |
| 1389 | + | |
| 1390 | + | |
| 1391 | + | |
| 1392 | + | |
| 1393 | + | |
| 1394 | + | |
| 1395 | + | |
| 1396 | + | |
| 1397 | + | |
| 1398 | + | |
1360 | 1399 | | |
1361 | 1400 | | |
1362 | 1401 | | |
| |||
6262 | 6301 | | |
6263 | 6302 | | |
6264 | 6303 | | |
| 6304 | + | |
| 6305 | + | |
| 6306 | + | |
| 6307 | + | |
| 6308 | + | |
| 6309 | + | |
| 6310 | + | |
| 6311 | + | |
| 6312 | + | |
| 6313 | + | |
| 6314 | + | |
| 6315 | + | |
| 6316 | + | |
| 6317 | + | |
6265 | 6318 | | |
6266 | 6319 | | |
6267 | 6320 | | |
| |||
0 commit comments