Skip to content

Commit

Permalink
ES6 generator: Simplify * handling in the class body.
Browse files Browse the repository at this point in the history
  • Loading branch information
ariya committed May 13, 2015
1 parent e549b16 commit 62780e4
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions esprima.js
Original file line number Diff line number Diff line change
Expand Up @@ -4808,15 +4808,15 @@
lex();
} else {
key = parseObjectPropertyKey();
}
if (key && key.name === 'static' && (lookaheadPropertyName() || match('*'))) {
token = lookahead;
isStatic = true;
computed = match('[');
if (match('*')) {
lex();
} else {
key = parseObjectPropertyKey();
if (key.name === 'static' && (lookaheadPropertyName() || match('*'))) {
token = lookahead;
isStatic = true;
computed = match('[');
if (match('*')) {
lex();
} else {
key = parseObjectPropertyKey();
}
}
}
method = tryParseMethodDefinition(token, key, computed, method);
Expand Down

0 comments on commit 62780e4

Please sign in to comment.