diff options
author | John MacFarlane <jgm@berkeley.edu> | 2019-01-22 21:39:26 -0800 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2019-01-22 21:39:26 -0800 |
commit | 5ddd7b121e1aea061b3e7b831dabbd13311929ff (patch) | |
tree | 173d57dd67230706d92b60cc150fe9c5896bc3be | |
parent | 3707bed4c1f211f5cebc22820ad6d70e36c04fcc (diff) | |
download | pandoc-5ddd7b121e1aea061b3e7b831dabbd13311929ff.tar.gz |
LaTeX reader: support `\endinput`. Closes #5233.
-rw-r--r-- | src/Text/Pandoc/Readers/LaTeX.hs | 1 | ||||
-rw-r--r-- | test/command/5233.md | 9 |
2 files changed, 10 insertions, 0 deletions
diff --git a/src/Text/Pandoc/Readers/LaTeX.hs b/src/Text/Pandoc/Readers/LaTeX.hs index f5d8527dd..5c0279fce 100644 --- a/src/Text/Pandoc/Readers/LaTeX.hs +++ b/src/Text/Pandoc/Readers/LaTeX.hs @@ -1765,6 +1765,7 @@ blockCommands = M.fromList addMeta "bibliography" . splitBibs . toksToString)) , ("addbibresource", mempty <$ (skipopts *> braced >>= addMeta "bibliography" . splitBibs . toksToString)) + , ("endinput", mempty <$ skipMany tok) -- includes , ("lstinputlisting", inputListing) , ("inputminted", inputMinted) diff --git a/test/command/5233.md b/test/command/5233.md new file mode 100644 index 000000000..0c92e955e --- /dev/null +++ b/test/command/5233.md @@ -0,0 +1,9 @@ +``` +% pandoc -f latex -t plain +foo +\endinput +bar +^D +foo +``` + |