Fixed bug in HTML comment parser.
Resolves Issue #157. ('try' in the wrong place.) git-svn-id: https://pandoc.googlecode.com/svn/trunk@1605 788f1e2b-df1e-0410-8736-df70ead52e1b
This commit is contained in:
parent
adabf14a5f
commit
1fe28483bd
1 changed files with 2 additions and 2 deletions
|
@ -346,8 +346,8 @@ rawHtmlBlock' = do notFollowedBy' (htmlTag "/body" <|> htmlTag "/html")
|
|||
htmlComment :: GenParser Char st [Char]
|
||||
htmlComment = try $ do
|
||||
string "<!--"
|
||||
comment <- many ( (satisfy (/='-'))
|
||||
<|> (char '-' >>~ notFollowedBy (try $ char '-' >> char '>')))
|
||||
comment <- many $ noneOf "-"
|
||||
<|> try (char '-' >>~ notFollowedBy (char '-' >> char '>'))
|
||||
string "-->"
|
||||
return $ "<!--" ++ comment ++ "-->"
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue