diff options
Diffstat (limited to 'test/compress/dead-code.js')
-rw-r--r-- | test/compress/dead-code.js | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/test/compress/dead-code.js b/test/compress/dead-code.js index 190a3243..501d55ec 100644 --- a/test/compress/dead-code.js +++ b/test/compress/dead-code.js @@ -1013,3 +1013,32 @@ issue_3406: { } expect_stdout: "true" } + +function_assign: { + options = { + dead_code: true, + } + input: { + console.log(function() { + var a = "PASS"; + function h(c) { + return c; + } + h.p = function(b) { + return b; + }.p = a; + return h; + }().p); + } + expect: { + console.log(function() { + var a = "PASS"; + function h(c) { + return c; + } + h.p = a; + return h; + }().p); + } + expect_stdout: "PASS" +} |