aboutsummaryrefslogtreecommitdiff
path: root/test/compress/negate-iife.js
AgeCommit message (Expand)Author
2018-07-01fix corner case in `unused`alexlamsl
2018-03-16improve truthy compression (#3009)Alex Lam S.L
2017-06-06implement function inlining (#2053)...- empty body - single `AST_Return` - single `AST_SimpleStatement` - avoid `/*#__PURE__*/` Miscellaneous - enhance single-use function substitution fixes #281Alex Lam S.L
2017-05-02improve literal return optimization (#1860)kzc
2017-03-27fix typeof side effects (#1696)...`statement_to_expression()` drops `typeof` even if it operates on undeclared variables. Since we now have `drop_side_effect_free()`, replace and remove this deprecated functionality.Alex Lam S.L
2017-03-19make `expect_stdout` work on Node.js 0.12 (#1623)...That particular version of Node.js has messed up error messages, so provide a version-specific workaround. Also fixed an formatting issue which would cause `expect_stdout` to fail if error message contains excerpts of input. Apply `expect_stdout` to more applicable tests.Alex Lam S.L
2017-03-03process code with implicit return statement (#1522)...Bookmarklet for instance implicitedly assumes a "completion value" without using `return`. The `expression` option now supports such use cases. Optimisations on IIFEs also enhanced. fixes #354 fixes #543 fixes #625 fixes #628 fixes #640 closes #1293Alex Lam S.L
2017-03-02optimize trivial IIFEs returning constants (#1530)kzc
2017-02-21fix duplicated test names...previously test cases with the same name would be skipped except for the last one `test/run-test.js` will now report duplicated names as errors closes #1461 alexlamsl
2017-02-21clean up `negate_iife`...- remove extra tree scanning phase for `negate_iife` - `negate_iife` now only deals with the narrowest form, i.e. IIFE sitting directly under `AST_SimpleStatement` - `booleans`, `conditionals` etc. will now take care the rest via more accurate accounting - `a(); void b();` => `a(); b();` fixes #1288 closes #1451 alexlamsl
2016-08-17Fix negate_iife transform to return a correct tree for nested IIFEs...Fix for #1256, partially reverts d854523783b4 Richard van Velzen
2016-08-17Fix negate_iife regression #1254kzc
2016-05-15Simplify iife `new` fix...as suggested by @rvanvelzen. Added a test for IIFEs in nested contexts. kzc
2016-05-09Do not apply negate_iife optimization to `new` expressionkzc
2013-12-29Conditional/call optimization... foo ? bar(x) : bar(y) ==> bar(foo ? x : y) Mihai Bazon
2013-08-20Move support for `negate_iife` in the compressor, rather than code generator...(the code generator doesn't maintain enough context to know whether the return value is important or discarded) Fixes #272 Mihai Bazon