mirror of
https://github.com/jgm/pandoc.git
synced 2026-09-25 17:05:41 +00:00
LaTeX reader: don't assume preamble doesn't contain environments.
Closes #1338.
This commit is contained in:
@@ -1134,7 +1134,7 @@ paragraph = do
|
||||
|
||||
preamble :: LP Blocks
|
||||
preamble = mempty <$> manyTill preambleBlock beginDoc
|
||||
where beginDoc = lookAhead $ controlSeq "begin" *> string "{document}"
|
||||
where beginDoc = lookAhead $ try $ controlSeq "begin" *> string "{document}"
|
||||
preambleBlock = (void comment)
|
||||
<|> (void sp)
|
||||
<|> (void blanklines)
|
||||
|
||||
Reference in New Issue
Block a user