 
   # Remove newlines from beginning and end of string literals.
   # `str` includes quotes.
-  trimAndEscapeLines: (str) ->
+  removeNewlines: (str) ->
     @escapeLines str.replace(/^(.)\s*\n\s*/, '$1').replace(/\s*\n\s*(.)$/, '$1')
 
   # Converts newlines for string literals.

      when "'"
        return 0 unless match = SIMPLESTR.exec @chunk
        string = match[0]
        @token 'STRING', @trimAndEscapeLines(string), 0, string.length
      when '"'
        return 0 unless string = @balancedString @chunk, '"'
        if 0 < string.indexOf '#{', 1
          @interpolateString string[1...-1], strOffset: 1, lexedLength: string.length
        else
          @token 'STRING', @trimAndEscapeLines(string), 0, string.length
      else
        return 0
    if octalEsc = /^(?:\\.|[^\\])*\\(?:0[0-7]|[1-7])/.test string


MULTI_DENT = /^(?:\n[^\n\S]*)+/

SIMPLESTR  = /^'[^\\']*(?:\\[\s\S][^\\']*)*'/

JSTOKEN    = /^`[^\\`]*(?:\\.[^\\`]*)*`/

