aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2020-12-17 05:51:34 +0000
committerGitHub <noreply@github.com>2020-12-17 13:51:34 +0800
commit75e9fd84174eaa8bf97975ad254fe06958564547 (patch)
tree4a3133a43cf7a04362b3ef8ba33ba6d57db06576 /test
parentf68e267830c94f129df4c9e93674abfafbc0125b (diff)
downloadtracifyjs-75e9fd84174eaa8bf97975ad254fe06958564547.tar.gz
tracifyjs-75e9fd84174eaa8bf97975ad254fe06958564547.zip
fix corner case in `arguments` (#4387)
fixes #4386
Diffstat (limited to 'test')
-rw-r--r--test/compress/destructured.js20
1 files changed, 20 insertions, 0 deletions
diff --git a/test/compress/destructured.js b/test/compress/destructured.js
index 9fd425d1..81beb7f7 100644
--- a/test/compress/destructured.js
+++ b/test/compress/destructured.js
@@ -1866,3 +1866,23 @@ issue_4383: {
expect_stdout: "1"
node_version: ">=6"
}
+
+issue_4386: {
+ options = {
+ arguments: true,
+ }
+ input: {
+ function f({}) {
+ return arguments[0];
+ }
+ console.log(f("PASS"));
+ }
+ expect: {
+ function f({}) {
+ return arguments[0];
+ }
+ console.log(f("PASS"));
+ }
+ expect_stdout: "PASS"
+ node_version: ">=6"
+}