aboutsummaryrefslogtreecommitdiff
path: root/bin/uglifyjs
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2021-02-18 18:04:33 +0000
committerGitHub <noreply@github.com>2021-02-19 02:04:33 +0800
commit10de27ca3d2010f45a1fb86b2707fa82e73b36b2 (patch)
tree71622ee56844fba68a0b57f52ea263f3092b39e2 /bin/uglifyjs
parent7b4fd858ba23e6c1402ad33d8cc4a8a8e7966614 (diff)
downloadtracifyjs-10de27ca3d2010f45a1fb86b2707fa82e73b36b2.tar.gz
tracifyjs-10de27ca3d2010f45a1fb86b2707fa82e73b36b2.zip
fix corner case in `reduce_vars` (#4665)
fixes #4664
Diffstat (limited to 'bin/uglifyjs')
-rwxr-xr-xbin/uglifyjs8
1 files changed, 4 insertions, 4 deletions
diff --git a/bin/uglifyjs b/bin/uglifyjs
index c2576ba0..60335426 100755
--- a/bin/uglifyjs
+++ b/bin/uglifyjs
@@ -10,7 +10,7 @@ var info = require("../package.json");
var path = require("path");
var UglifyJS = require("../tools/node");
-var skip_keys = [ "cname", "inlined", "parent_scope", "scope", "uses_eval", "uses_with" ];
+var skip_keys = [ "cname", "fixed", "inlined", "parent_scope", "scope", "uses_eval", "uses_with" ];
var files = {};
var options = {};
var short_forms = {
@@ -360,14 +360,14 @@ function run() {
}
print(JSON.stringify(result.ast, function(key, value) {
if (value) switch (key) {
- case "thedef":
- return symdef(value);
case "enclosed":
return value.length ? value.map(symdef) : undefined;
- case "variables":
case "functions":
case "globals":
+ case "variables":
return value.size() ? value.map(symdef) : undefined;
+ case "thedef":
+ return symdef(value);
}
if (skip_key(key)) return;
if (value instanceof UglifyJS.AST_Token) return;