class Haml::Parser
def is_ruby_multiline?(text)
- and not "?\," which is a character literal
(however, "x?," is a method call and not a literal)
- but not "?," which is a character literal
- ends with a comma
`text' is a Ruby multiline block if it:
def is_ruby_multiline?(text) text && text.length > 1 && text[-1] == ?, && !((text[-3..-2] =~ /\W\?/) || text[-3..-2] == "?\\") end