Overhaul the regular expressions
Overhaul the regular expressions

- Bring the 3 regexes into one place as constants.  Makes it
  clear what they are and easier to keep track of
- Make MD_LINK_PAT account for links with nested parentheses
- Make TOC_PAT assert that <!---toc start--> starts a line
  and that <!---toc end--> ends one

This commit also makes get_links() into a generator

scottfrazer/mdtoc