Skip to content

Commit

Permalink
fixed files form Closure #42
Browse files Browse the repository at this point in the history
  • Loading branch information
tdurieux committed Mar 7, 2017
1 parent 63276f8 commit fe6a63a
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -565,8 +565,15 @@ Node processExpressionStatement(ExpressionStatement statementNode) {

@Override
Node processForInLoop(ForInLoop loopNode) {
if (loopNode.isForEach()) {
errorReporter.error(
"unsupported language extension: for each",
sourceName,
loopNode.getLineno(), "", 0);

// Return the bare minimum to put the AST in a valid state.
return newNode(Token.EXPR_RESULT, Node.newNumber(0));
}
return newNode(
Token.FOR,
transform(loopNode.getIterator()),
Expand Down

0 comments on commit fe6a63a

Please sign in to comment.