diff options
author | Alex Lam S.L <alexlamsl@gmail.com> | 2018-02-28 15:19:32 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-02-28 15:19:32 +0800 |
commit | 36bca6934de494a79a1c1af952653eaaf9c15ed8 (patch) | |
tree | b7f98d8ef621eef6289a233c40f3cea0073bfc06 /test/compress/sequences.js | |
parent | ace581169134d9b6d4cdf6b24880f7ce122fc88e (diff) | |
download | tracifyjs-36bca6934de494a79a1c1af952653eaaf9c15ed8.tar.gz tracifyjs-36bca6934de494a79a1c1af952653eaaf9c15ed8.zip |
enhance `collapse_vars` (#2952)
- `a = b, b` => `a = b`
- `a.b = c, c()` => `(a.b = c)()`
Diffstat (limited to 'test/compress/sequences.js')
-rw-r--r-- | test/compress/sequences.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/test/compress/sequences.js b/test/compress/sequences.js index 03075bf1..12acbcf7 100644 --- a/test/compress/sequences.js +++ b/test/compress/sequences.js @@ -668,8 +668,7 @@ side_effects_cascade_2: { } expect: { function f(a, b) { - b = a, - !a + (b += a) || (b += a), + !(b = a) + (b += a) || (b += a), b = a; } } |