From 0f0c1579f870248566abe806ff7bb6cc866ab4dc Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Mon, 25 Jul 2011 23:49:45 -0700 Subject: Smart quotes: handle '...hi' properly. Also added test case. --- src/Text/Pandoc/Parsing.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/Text/Pandoc') diff --git a/src/Text/Pandoc/Parsing.hs b/src/Text/Pandoc/Parsing.hs index c16d99bdf..700076a10 100644 --- a/src/Text/Pandoc/Parsing.hs +++ b/src/Text/Pandoc/Parsing.hs @@ -759,7 +759,8 @@ singleQuoteStart :: GenParser Char ParserState () singleQuoteStart = do failIfInQuoteContext InSingleQuote try $ do charOrRef "'\8216\145" - notFollowedBy (oneOf ")!],.;:-? \t\n") + notFollowedBy (oneOf ")!],;:-? \t\n") + notFollowedBy (char '.') <|> lookAhead (string "..." >> return ()) notFollowedBy (try (oneOfStrings ["s","t","m","ve","ll","re"] >> satisfy (not . isAlphaNum))) -- possess/contraction -- cgit v1.2.3