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
c66921f2ac
This commit is contained in:
John MacFarlane 2010-12-14 18:22:20 -08:00
parent 2e728df756
commit 128cf46089

View file

@ -1059,7 +1059,7 @@ strChar = noneOf (specialChars ++ " \t\n")
str :: GenParser Char ParserState Inline
str = do
a <- strChar
as <- many (strChar <|> (try $ char '_' >>~ lookAhead strChar))
as <- many (strChar <|> (try $ char '_' >>~ lookAhead alphaNum))
let result = a:as
state <- getState
let spacesToNbr = map (\c -> if c == ' ' then '\160' else c)