class Kramdown::Parser::Kramdown

def parse_smart_quotes

Parse the smart quotes at current location.
def parse_smart_quotes
  regexp, substs = SQ_RULES.find {|reg, subst| @src.scan(reg)}
  substs.each do |subst|
    if subst.kind_of?(Integer)
      add_text(@src[subst])
    else
      val = SQ_SUBSTS[[subst, @src[subst.to_s[-1,1].to_i]]] || subst
      @tree.children << Element.new(:smart_quote, val)
    end
  end
end