git.iko.soy/typeable/pandoc
on master help sign in
Fixed regression in parsing _emph_

There was a bug in parsing '_emph_, ...': when followed by a comma, underscore emphasis did not register. (Thanks to gwern for pointing this out.) This bug was introduced by the change in c66921f2acea456af527b93e2daa1d8594798642

commit128cf46089f5a2fa688097f596563ecefd9c466b authorJohn MacFarlane <jgm@berkeley.edu> dateTue 14 Dec 2010, 18:22 (16 years ago) parent2e728df
1 file changed+1−1
src/Text/Pandoc/Readers/Markdown.hs+1−1
src/Text/Pandoc/Readers/Markdown.hs+1−1
@@ -1059,7 +1059,7 @@ strChar = noneOf (specialChars ++ " \t\n")
10591059str :: GenParser Char ParserState Inline
10601060str = do
10611061 a <- strChar
1062− as <- many (strChar <|> (try $ char '_' >>~ lookAhead strChar))
1062+ as <- many (strChar <|> (try $ char '_' >>~ lookAhead alphaNum))
10631063 let result = a:as
10641064 state <- getState
10651065 let spacesToNbr = map (\c -> if c == ' ' then '\160' else c)