diff options
Diffstat (limited to 'test/compress/hoist_props.js')
-rw-r--r-- | test/compress/hoist_props.js | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/test/compress/hoist_props.js b/test/compress/hoist_props.js index dbee9b42..597db4bc 100644 --- a/test/compress/hoist_props.js +++ b/test/compress/hoist_props.js @@ -1068,3 +1068,29 @@ issue_4023: { } expect_stdout: "true" } + +object_super: { + options = { + hoist_props: true, + reduce_vars: true, + toplevel: true, + } + input: { + var o = { + f(a) { + return a ? console.log("PASS") : super.log("PASS"); + }, + }; + o.f(42); + } + expect: { + var o = { + f(a) { + return a ? console.log("PASS") : super.log("PASS"); + }, + }; + o.f(42); + } + expect_stdout: "PASS" + node_version: ">=4" +} |