Changed definition of 'emph': italics with '_' must not be followed
by an alphanumeric character. This is to help prevent interpretation
of e.g. [LC_TYPE]: my_type as '[LC<em>TYPE]:my</em>type'.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@974 788f1e2b-df1e-0410-8736-df70ead52e1b
commitc206332558ad3ef4607c701cfa688695197f24e1
authorfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b>
dateFri 31 Aug 2007, 22:15 (19 years ago)
parent0c09f4c
src/Text/Pandoc/Readers/Markdown.hs+1−1
@@ -686,7 +686,7 @@ math = try $ do
686686 return $ TeX ("$" ++ (joinWithSep " " words) ++ "$")
687687
688688emph = ((enclosed (char '*') (char '*') inline) <|>
689− (enclosed (char '_') (char '_') inline)) >>=
689+ (enclosed (char '_') (char '_' >> notFollowedBy alphaNum) inline)) >>=
690690 return . Emph . normalizeSpaces
691691
692692strong = ((enclosed (string "**") (try $ string "**") inline) <|>