git.iko.soy/typeable/pandoc
on master help sign in
RST reader: fix bug with internal link targets.
37c6f6aJohn MacFarlane
src/Text/Pandoc/Readers/RST.hs+1−1
@@ -1090,7 +1090,7 @@ referenceKey = do
1090targetURI :: Monad m => ParserT [Char] st m [Char]
1090targetURI :: Monad m => ParserT [Char] st m [Char]
1091targetURI = do
1091targetURI = do
1092 skipSpaces
1092 skipSpaces
1093− optional newline
1093+ optional $ try $ newline >> notFollowedBy blankline
1094 contents <- trim <$>
1094 contents <- trim <$>
1095 many1 (satisfy (/='\n')
1095 many1 (satisfy (/='\n')
1096 <|> try (newline >> many1 spaceChar >> noneOf " \t\n"))
1096 <|> try (newline >> many1 spaceChar >> noneOf " \t\n"))
test/command/4919.mdnew file+14
@@ -0,0 +1,14 @@
1+```
2+% pandoc -f rst -t native
3+.. _`tgtmath`:
4+
5+ .. math::
6+ :name:
7+
8+ V = \frac{K}{r^2}
9+^D
10+[Div ("tgtmath",[],[])
11+ [BlockQuote
12+ [Para [Math DisplayMath "V = \\frac{K}{r^2}"]]]]
13+```
14+