class Haml::HTML

def match_to_html(string, regex, tag)

def match_to_html(string, regex, tag)
  string.gsub!(regex) do
    "<haml:#{tag}>#{CGI.escapeHTML($1)}</haml:#{tag}>"
  end
end