class Temple::ERB::Parser
def call(input)
def call(input) result = [:multi] pos = 0 input.scan(ERB_PATTERN) do |escaped, indicator, code| m = Regexp.last_match text = input[pos...m.begin(0)] pos = m.end(0) result << [:static, text] if !text.empty? if escaped result << [:static, ESCAPED[escaped]] else case indicator when '#' code.count("\n").times { result << [:newline] } when /=/ result << [:escape, indicator.length <= 1 && options[:auto_escape], [:dynamic, code]] else result << [:block, code] end end end result << [:static, input[pos..-1]] end