diff options
author | John MacFarlane <jgm@berkeley.edu> | 2021-03-09 13:03:27 -0800 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2021-03-09 13:03:27 -0800 |
commit | 1c23e3a824bc4d850a908193443ad1915a3ebc61 (patch) | |
tree | 4119ba4c9713c25b1792520c8cf97ea56c2b9f82 /src/Text/Pandoc | |
parent | a8b2031bb43aaca9b4c5643d8d118166f93041c3 (diff) | |
download | pandoc-1c23e3a824bc4d850a908193443ad1915a3ebc61.tar.gz |
RST reader: fix logic for ending comments.
Previously comments sometimes got extended too far. Closes #7134.
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r-- | src/Text/Pandoc/Readers/RST.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/RST.hs b/src/Text/Pandoc/Readers/RST.hs index 29f81b046..514e3b88d 100644 --- a/src/Text/Pandoc/Readers/RST.hs +++ b/src/Text/Pandoc/Readers/RST.hs @@ -613,8 +613,9 @@ comment = try $ do string ".." skipMany1 spaceChar <|> (() <$ lookAhead newline) -- notFollowedBy' directiveLabel -- comment comes after directive so unnec. - manyTill anyChar blanklines + _ <- anyLine optional indentedBlock + optional blanklines return mempty directiveLabel :: Monad m => RSTParser m Text |