Markdown: don't recognize references inside delimited code blocks.
Previously pandoc would produce incorrect results on this: ~~~ [not a link]: /url ~~~ [not a link] because it would recognize "not a link" as a reference link definition on the first pass. This fix causes the first pass to skip delimited code blocks.
This commit is contained in:
parent
dbbc932f24
commit
d28ad2b0f1
1 changed files with 1 additions and 0 deletions
|
@ -183,6 +183,7 @@ parseMarkdown = do
|
|||
st <- getState
|
||||
let firstPassParser = referenceKey
|
||||
<|> (if stateStrict st then pzero else noteBlock)
|
||||
<|> liftM snd (withRaw codeBlockDelimited)
|
||||
<|> lineClump
|
||||
docMinusKeys <- liftM concat $ manyTill firstPassParser eof
|
||||
setInput docMinusKeys
|
||||
|
|
Loading…
Add table
Reference in a new issue