Debugging rewriting Markdown logic as regex vs. exploding each line