Commit Graph

11 Commits

Author SHA1 Message Date
Donny/강동윤
57204e39cd
fix(es/minifier): Don't inline functions used as arguments ()
swc_ecma_minifier:
 - Preserve a variable initialized with a function expression if it's used as an argument.
2022-01-20 16:06:23 +09:00
Donny/강동윤
74fd353053
fix(es/minifier): Fix bugs ()
swc_ecma_minifier:
 - `collapse_vars`: Respect `mutated`. (Closes )
 - Add a test for https://github.com/vercel/next.js/issues/31084.
2022-01-12 16:57:54 +09:00
Donny/강동윤
12dd0a6c1f
fix(es/minifier): Fix optimization of assignment expressions ()
swc_ecma_minifier:
 - Check if the operator is `=` before optimizing assignment with a binary expression.
2022-01-12 08:26:56 +09:00
Donny/강동윤
78720c4c91
fix(es/minifier): Fix handling of inlined call to a hoisted function () 2022-01-11 19:37:06 +09:00
Donny/강동윤
057fca4196
chore(es/minifier): Add scripts to extract tests automatically () 2022-01-10 16:59:21 +09:00
Donny/강동윤
1c1c9f0eae
fix(es/minifier): Fix bugs ()
swc_ecma_minifier:
 - Improve the script for extracting inputs from next.js app.
 - Ensure the name is removed on inlining.
 - Respect `inline_prevented`.
2022-01-05 05:12:52 +09:00
Donny/강동윤
d482d61b9f
chore(scripts): Use cargo profile instruments instead of cargo instruments () 2021-12-21 16:09:19 +09:00
Donny/강동윤
6b96a3d8ed
feat: Enable logging of timings ()
swc_timer:
 - Add `Timer`.
 - Add `timer!()`.

node:
 - Enable logging.
2021-11-22 21:01:08 +09:00
Donny/강동윤
fa342a0067
fix(es/minifier): Fix bugs ()
swc_ecma_minifier:
 - Don't optimize `1 / t == -1 / 0` as `!1`.
 - Don't optimize `e === -1 / 0` as false.
 - Don't inline string literals in arguments, if it's used multiple time. (https://github.com/vercel/next.js/issues/31291)
2021-11-20 17:06:18 +09:00
Donny/강동윤
e1b76654f5
chore(es/minifier): Add a script to copy tests from a next.js app () 2021-11-17 16:18:34 +09:00
Donny/강동윤
2b2f6955f2
refactor: Flatten ecmascript () 2021-11-10 19:00:54 +09:00