LibJS: Allow binding patterns as for in/of targets

This commit is contained in:
Ali Mohammad Pur 2021-07-02 14:55:53 +04:30 committed by Andreas Kling
commit a6fe27423a
Notes: sideshowbarker 2024-07-18 11:07:37 +09:00
3 changed files with 9 additions and 1 deletions

View file

@ -49,3 +49,7 @@ test("use already-declared variable", () => {
for (property in "abc");
expect(property).toBe("2");
});
test("allow binding patterns", () => {
expect(`for (let [a, b] in foo) {}`).toEval();
});