Added tests for ASI and element access with 'let'.

This commit is contained in:
Daniel Rosenwasser
2016-02-20 00:58:20 -08:00
parent 11ec01b476
commit b71ec381f9
3 changed files with 12 additions and 0 deletions

View File

@@ -0,0 +1,4 @@
// @target:es6
let
x

View File

@@ -0,0 +1,6 @@
// @target:es6
// An ExpressionStatement cannot start with the two token sequence `let [` because
// that would make it ambiguous with a `let` LexicalDeclaration whose first LexicalBinding was an ArrayBindingPattern.
var let: any;
let[0] = 100;

View File

@@ -0,0 +1,2 @@
var let: any = {};
(let[0] = 100);