aboutsummaryrefslogtreecommitdiff
path: root/test/ufuzz/index.js
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2021-02-23 21:57:11 +0000
committerGitHub <noreply@github.com>2021-02-24 05:57:11 +0800
commitc88566034756eb17c4ff563901b3a1c95b63f788 (patch)
tree24e376db8595b8152b2685708ee08b7f9e194758 /test/ufuzz/index.js
parentd68d155f93a355a9f6f0451150186b7fad8c58b8 (diff)
downloadtracifyjs-c88566034756eb17c4ff563901b3a1c95b63f788.tar.gz
tracifyjs-c88566034756eb17c4ff563901b3a1c95b63f788.zip
support nullish coalescing operator (#4678)
Diffstat (limited to 'test/ufuzz/index.js')
-rw-r--r--test/ufuzz/index.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/ufuzz/index.js b/test/ufuzz/index.js
index 0625a267..3d0824b6 100644
--- a/test/ufuzz/index.js
+++ b/test/ufuzz/index.js
@@ -149,6 +149,7 @@ var SUPPORT = function(matrix) {
for_of: "for (var a of []);",
generator: "function* f(){}",
let: "let a;",
+ nullish: "0 ?? 0",
rest: "var [...a] = [];",
rest_object: "var {...a} = {};",
spread: "[...[]];",
@@ -231,6 +232,7 @@ var BINARY_OPS = [
",",
];
BINARY_OPS = BINARY_OPS.concat(BINARY_OPS);
+if (SUPPORT.nullish) BINARY_OPS.push("??");
BINARY_OPS = BINARY_OPS.concat(BINARY_OPS);
BINARY_OPS = BINARY_OPS.concat(BINARY_OPS);
if (SUPPORT.exponentiation) BINARY_OPS.push("**");