Throw error if new.target is like new.foo
This commit is contained in:
@@ -1448,7 +1448,7 @@ function parse($TEXT, options) {
|
||||
expect_token("operator", "new");
|
||||
if (is("punc", ".")) {
|
||||
next();
|
||||
expect_token("name");
|
||||
expect_token("name", "target");
|
||||
return subscripts(new AST_NewTarget({
|
||||
start : start,
|
||||
end : prev()
|
||||
|
||||
Reference in New Issue
Block a user