Fix object destructuring for empty pattern (#3571)

JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik [email protected]
This commit is contained in:
Robert Fancsik authored and GitHub committed 2020-03-02 15:37:03 +01:00
1 parent f31931267a
commit ec39d08d67
7 files changed
+27 -2

No files matched your search

+2
View File
@@ -54,6 +54,8 @@ checkSyntax ("let {a:(a)} = {a:1}");
mustThrow ("var {a} = null");
mustThrow ("var {a} = undefined");
mustThrow ("function f ({a : {}}) {}; f({});");
mustThrow ("function f ({}) {}; f();");
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Destructuring_assignment