@@ -59,7 +59,7 @@ hruleChars = "*-_"
5959setextHChars = "=-"
6060
6161-- treat these as potentially non-text when parsing inline:
62−specialChars = "\\[]*_~`<>$!^-.&'\""
62+specialChars = "\\[]*_~`<>$!^-.&'\"\8216\8217\8220\8221"
6363
6464--
6565-- auxiliary functions
@@ -766,13 +766,17 @@ singleQuoteStart = do
766766 satisfy (not . isAlphaNum))) -- possess/contraction
767767 return '\''
768768
769−singleQuoteEnd = (char '\'' <|> char '\8217') >> notFollowedBy alphaNum
769+singleQuoteEnd = char '\8217' <|>
770+ (char '\'' >> notFollowedBy alphaNum >> return '\'')
770771
771−doubleQuoteStart = failIfInQuoteContext InDoubleQuote >>
772− (char '"' <|> char '\8220') >>
773− notFollowedBy (oneOf " \t\n")
772+doubleQuoteStart = do
773+ failIfInQuoteContext InDoubleQuote
774+ char '\8220' <|>
775+ do char '"'
776+ notFollowedBy (oneOf " \t\n")
777+ return '"'
774778
775−doubleQuoteEnd = char '"' <|> char '\8221'
779+doubleQuoteEnd = char '\8221' <|> char '"'
776780
777781ellipses = oneOfStrings ["...", " . . . ", ". . .", " . . ."] >> return Ellipses
778782