diff options
author | John MacFarlane <jgm@berkeley.edu> | 2021-08-23 22:06:39 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2021-08-23 22:06:39 -0700 |
commit | 3f9b7a10ad2de63f6a9c77ff361acf17f94d536b (patch) | |
tree | 5f19327c4161a4cfbe82118f1a86cc80af2822a3 /src/Text | |
parent | 5a23f8ff3eaa4051da3371da50a11b601f27d889 (diff) | |
download | pandoc-3f9b7a10ad2de63f6a9c77ff361acf17f94d536b.tar.gz |
Markdown reader: fix interaction of --strip-comments and list
parsing. Use of `--strip-comments` was causing tight lists
to be rendered as loose (as if the comment were a blank line).
Closes #7521.
Diffstat (limited to 'src/Text')
-rw-r--r-- | src/Text/Pandoc/Readers/Markdown.hs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/Markdown.hs b/src/Text/Pandoc/Readers/Markdown.hs index 0f2239394..45594e0fa 100644 --- a/src/Text/Pandoc/Readers/Markdown.hs +++ b/src/Text/Pandoc/Readers/Markdown.hs @@ -829,7 +829,7 @@ listLineCommon :: PandocMonad m => MarkdownParser m Text listLineCommon = T.concat <$> manyTill ( many1Char (satisfy $ \c -> c `notElem` ['\n', '<', '`']) <|> fmap snd (withRaw code) - <|> fmap snd (htmlTag isCommentTag) + <|> fmap (renderTags . (:[]) . fst) (htmlTag isCommentTag) <|> countChar 1 anyChar ) newline |