From 54c9d4348ad0b61713ab16ebf20d640f60ea5c39 Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Tue, 10 Apr 2012 18:25:18 -0700 Subject: LaTeX reader: Control sequences can't be followed by a letter. This fixes a bug where `\begingroup` was parsed as `\begin` followed by `group`. --- src/Text/Pandoc/Readers/LaTeX.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Text/Pandoc/Readers') diff --git a/src/Text/Pandoc/Readers/LaTeX.hs b/src/Text/Pandoc/Readers/LaTeX.hs index cc71b49f2..1c1d5cad7 100644 --- a/src/Text/Pandoc/Readers/LaTeX.hs +++ b/src/Text/Pandoc/Readers/LaTeX.hs @@ -82,7 +82,7 @@ controlSeq name = try $ do case name of "" -> mzero [c] | not (isLetter c) -> string [c] - cs -> string cs <* optional sp + cs -> string cs <* notFollowedBy letter <* optional sp return name sp :: LP () -- cgit v1.2.3