Draft: More uri parsing fixes
Would fix #11145 if it didn't break it even more for _*http://links in nested spans*_
. This might require proper recursion in the parser.
The second commit fixes this funny corner case:
and makes the markup algorithm less weird and inefficient overall.