git.iko.soy/typeable/pandoc
on master help sign in
Textile reader: Avoid parsing dashes as strikeout.

Previously the input text-- text-- text-- text-- would be parsed with strikeouts rather than dashes. This fixes the problem by requiring that a strikeout delimiting - not be followed by a -. Closes #631.

commitae68836352afae134510b93b29983cb207fa37d0 authorJohn MacFarlane <jgm@berkeley.edu> dateFri 28 Sep 2012, 23:37 (14 years ago) parent632fd49
1 file changed+1−1
src/Text/Pandoc/Readers/Textile.hs+1−1
src/Text/Pandoc/Readers/Textile.hs+1−1
@@ -374,7 +374,7 @@ inlineMarkup = choice [ simpleInline (string "??") (Cite [])
374374 , simpleInline (char '*') Strong
375375 , simpleInline (char '_') Emph
376376 , simpleInline (char '+') Emph -- approximates underline
377− , simpleInline (char '-') Strikeout
377+ , simpleInline (char '-' <* notFollowedBy (char '-')) Strikeout
378378 , simpleInline (char '^') Superscript
379379 , simpleInline (char '~') Subscript
380380 ]