Fix eager parsing of arrow functions for non-punc tokens
This commit is contained in:
committed by
Richard van Velzen
parent
0b303379c0
commit
6780d0906c
@@ -1794,7 +1794,7 @@ function parse($TEXT, options) {
|
||||
var maybe_assign = function(no_in) {
|
||||
var start = S.token;
|
||||
|
||||
if (start.value == "(" && peek().value == ")") {
|
||||
if (start.type == "punc" && start.value == "(" && peek().value == ")") {
|
||||
next();
|
||||
next();
|
||||
return arrow_function([]);
|
||||
|
||||
Reference in New Issue
Block a user