diff --git a/lib/coffee_script/lexer.rb b/lib/coffee_script/lexer.rb index 20f227ca..27f0795e 100644 --- a/lib/coffee_script/lexer.rb +++ b/lib/coffee_script/lexer.rb @@ -27,7 +27,7 @@ module CoffeeScript COMMENT = /\A((#[^\n]*\s*)+)/m CODE = /\A(=>)/ REGEX = /\A(\/(.*?)[^\\]\/[imgy]{0,4})/ - MULTI_DENT = /\A((\n+[ \t]*)+)/ + MULTI_DENT = /\A((\n+([ \t]*(?=\S)))+)/ LAST_DENT = /\n+([ \t]*)\Z/ # Token cleaning regexes. diff --git a/test/fixtures/execution/test_calling_super.coffee b/test/fixtures/execution/test_calling_super.coffee index d2d6ed0d..8a9d4bc1 100644 --- a/test/fixtures/execution/test_calling_super.coffee +++ b/test/fixtures/execution/test_calling_super.coffee @@ -6,12 +6,12 @@ FirstChild: => FirstChild extends Base FirstChild.prototype.func: string => super('one/') + string - + SecondChild: => SecondChild extends FirstChild SecondChild.prototype.func: string => super('two/') + string - + ThirdChild: => ThirdChild extends SecondChild ThirdChild.prototype.func: string =>