Merge pull request #3190 from hzoo/remove-await-star

Remove await* from babel-generator, add parsing error to babylon - (fixes T6688)
This commit is contained in:
Amjad Masad
2015-12-22 22:57:23 -08:00
12 changed files with 19 additions and 19 deletions

View File

@@ -968,7 +968,9 @@ pp.parseAwait = function (node) {
if (this.isLineTerminator()) {
this.unexpected();
}
node.all = this.eat(tt.star);
if (this.match(tt.star)) {
this.raise(node.start, "await* has been removed from the async functions proposal. Use Promise.all() instead.")
}
node.argument = this.parseMaybeUnary();
return this.finishNode(node, "AwaitExpression");
};