From 3a66aab59db7fc80b07fd04d07293f6a235faf27 Mon Sep 17 00:00:00 2001 From: Corey Johnson & Nathan Sobo Date: Fri, 28 Sep 2012 09:40:06 -0700 Subject: [PATCH] getLineTokens must clone the ruleStack --- src/app/text-mate-grammar.coffee | 1 + 1 file changed, 1 insertion(+) diff --git a/src/app/text-mate-grammar.coffee b/src/app/text-mate-grammar.coffee index d78446461..5978b99ce 100644 --- a/src/app/text-mate-grammar.coffee +++ b/src/app/text-mate-grammar.coffee @@ -26,6 +26,7 @@ class TextMateGrammar @repository[name] = new Rule(this, data) getLineTokens: (line, stack=[@initialRule]) -> + stack = new Array(stack...) # clone stack tokens = [] position = 0