aboutsummaryrefslogtreecommitdiff
path: root/src/Text
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2015-12-22 11:06:06 -0800
committerJohn MacFarlane <jgm@berkeley.edu>2015-12-22 11:06:06 -0800
commit35e05449777255b624f0e8cb374e1fcdca86ba78 (patch)
tree5a2fb40942fdf31212b2080e2b25d551bfe3611f /src/Text
parent46e38d0a0a8d4e0cd4054dff19c4dd383ac7ae1c (diff)
downloadpandoc-35e05449777255b624f0e8cb374e1fcdca86ba78.tar.gz
LaTeX reader: allow blank space between braced arguments of commands.
For example \foo {bar} {baz} Closes #2592.
Diffstat (limited to 'src/Text')
-rw-r--r--src/Text/Pandoc/Readers/LaTeX.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/LaTeX.hs b/src/Text/Pandoc/Readers/LaTeX.hs
index 5a4612862..d2e8d9d17 100644
--- a/src/Text/Pandoc/Readers/LaTeX.hs
+++ b/src/Text/Pandoc/Readers/LaTeX.hs
@@ -132,7 +132,9 @@ comment = do
return ()
bgroup :: LP ()
-bgroup = () <$ char '{'
+bgroup = try $ do
+ skipMany (spaceChar <|> try (newline <* notFollowedBy blankline))
+ () <$ char '{'
<|> () <$ controlSeq "bgroup"
<|> () <$ controlSeq "begingroup"