correctly count declarations after hoist_vars (#2297)

fixes #2295
This commit is contained in:
Alex Lam S.L
2017-09-03 17:23:31 +08:00
committed by GitHub
parent 71d52f147d
commit 3f355866cf
2 changed files with 22 additions and 0 deletions

View File

@@ -3113,6 +3113,7 @@ merge(Compressor.prototype, {
}));
if (reduce_vars) name.definition().fixed = false;
}
remove(def.name.definition().orig, def.name);
return a;
}, []);
if (assignments.length == 0) return null;