git.iko.soy/typeable/pandoc
on master help sign in
Markdown reader: Fixed small bug in HTML parsing with markdown_attribute.

Test case: <aside markdown="1"> *hi* </aside> Previously gave: <article markdown="1"> <p><em>hi</em> </article></p>

commita243afb55104b0e5e1ddf62f301477a545381634 authorJohn MacFarlane <jgm@berkeley.edu> dateSun 20 Jul 2014, 17:22 (12 years ago) parent4d2e6e8
1 file changed+4−3
src/Text/Pandoc/Readers/Markdown.hs+4−3
src/Text/Pandoc/Readers/Markdown.hs+4−3
@@ -1404,8 +1404,7 @@ escapedChar = do
14041404ltSign :: MarkdownParser (F Inlines)
14051405ltSign = do
14061406 guardDisabled Ext_raw_html
1407− <|> guardDisabled Ext_markdown_in_html_blocks
1408− <|> (notFollowedBy' (htmlTag isBlockTag) >> return ())
1407+ <|> (notFollowedByHtmlCloser >> notFollowedBy' (htmlTag isBlockTag))
14091408 char '<'
14101409 return $ return $ B.str "<"
14111410
@@ -1797,7 +1796,9 @@ rawHtmlInline = do
17971796 Just t' -> t ~== TagClose t'
17981797 Nothing -> False
17991798 mdInHtml <- option False $
1800− guardEnabled Ext_markdown_in_html_blocks >> return True
1799+ ( guardEnabled Ext_markdown_in_html_blocks
1800+ <|> guardEnabled Ext_markdown_attribute
1801+ ) >> return True
18011802 (_,result) <- htmlTag $ if mdInHtml
18021803 then (\x -> isInlineTag x &&
18031804 not (isCloseBlockTag x))