diff options
author | Mihai Bazon <mihai@bazon.net> | 2012-10-18 15:14:57 +0300 |
---|---|---|
committer | Mihai Bazon <mihai@bazon.net> | 2012-10-18 15:14:57 +0300 |
commit | afb7faa6fadee46a6ab46232eddba2121c77549b (patch) | |
tree | 5d472b568192e15812dbf74c63790abf78ce984b /lib/ast.js | |
parent | 6aa56f92fe07edfc677d390a2e26b37c98da0968 (diff) | |
download | tracifyjs-afb7faa6fadee46a6ab46232eddba2121c77549b.tar.gz tracifyjs-afb7faa6fadee46a6ab46232eddba2121c77549b.zip |
more optimizations for some break/continue cases
Diffstat (limited to 'lib/ast.js')
-rw-r--r-- | lib/ast.js | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -929,10 +929,10 @@ TreeWalker.prototype = { } else { for (var i = stack.length; --i >= 0;) { var x = stack[i]; - if (x instanceof AST_Switch) return x; - if (x instanceof AST_For || x instanceof AST_ForIn || x instanceof AST_DWLoop) { - return (x.body instanceof AST_BlockStatement ? x.body : x); - } + if (x instanceof AST_Switch + || x instanceof AST_For + || x instanceof AST_ForIn + || x instanceof AST_DWLoop) return x; } } } |