LaTeX reader: guard against "begin"/"end" in blockCommand.
commit14dba12f9058790a5ea4d29d44e044b5f1213c23
authorJohn MacFarlane <fiddlosopher@gmail.com>
dateSun 9 Sep 2012, 18:27 (14 years ago)
parentccf3148
src/Text/Pandoc/Readers/LaTeX.hs+1
@@ -214,6 +214,7 @@ blocks = mconcat <$> many block
214214blockCommand :: LP Blocks
215215blockCommand = try $ do
216216 name <- anyControlSeq
217+ guard $ name /= "begin" && name /= "end"
217218 star <- option "" (string "*" <* optional sp)
218219 let name' = name ++ star
219220 case M.lookup name' blockCommands of