From 6bbdf42da827cab3c6036ec0b9c426dc9f664d5e Mon Sep 17 00:00:00 2001 From: Kevin Dangoor Date: Mon, 22 Jul 2013 10:25:36 -0400 Subject: [PATCH] Simple workaround for a v8 crash. The crash occurs sometimes when parsing certain JS files. This works around the crash by causing the `next()` function to be deoptimized. --- acorn.js | 1 + 1 file changed, 1 insertion(+) diff --git a/acorn.js b/acorn.js index 43db6e9e0..72d38a6e8 100644 --- a/acorn.js +++ b/acorn.js @@ -937,6 +937,7 @@ // Continue to the next token. function next() { + eval(true); lastStart = tokStart; lastEnd = tokEnd; lastEndLoc = tokEndLoc;