From 4399db4fd2d3f1f936e21cd0fe732142a7fccab2 Mon Sep 17 00:00:00 2001 From: fiddlosopher Date: Sat, 18 Aug 2007 23:44:26 +0000 Subject: Bug fixes in readers: + LaTeX reader: skip anything after \end{document} + HTML reader: fixed bug skipping material after -- previously, stuff at the end was skipped even if no was present, which meant only part of the file would be parsed and no error issued + HTML reader: added new constant eitherBlockOrInline with elements that may count either as block-level or inline + Modified isInline and isBlock to take this into account + modified rawHtmlBlock to accept any tag (even an inline tag); this is innocuous, because rawHtmlBlock is tried only if a regular inline element can't be parsed. git-svn-id: https://pandoc.googlecode.com/svn/trunk@862 788f1e2b-df1e-0410-8736-df70ead52e1b --- src/Text/Pandoc/Readers/LaTeX.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/Text/Pandoc/Readers/LaTeX.hs') diff --git a/src/Text/Pandoc/Readers/LaTeX.hs b/src/Text/Pandoc/Readers/LaTeX.hs index 84bda1942..9440b446a 100644 --- a/src/Text/Pandoc/Readers/LaTeX.hs +++ b/src/Text/Pandoc/Readers/LaTeX.hs @@ -117,7 +117,8 @@ parseLaTeX = do spaces blocks <- parseBlocks spaces - optional $ try (string "\\end{document}") -- might not be present (fragment) + optional $ try (string "\\end{document}" >> many anyChar) + -- might not be present (fragment) spaces eof state <- getState -- cgit v1.2.3