pandoc/test
John MacFarlane 0feb7504b1 Rewrote LaTeX reader with proper tokenization.
This rewrite is primarily motivated by the need to
get macros working properly.  A side benefit is that the
reader is significantly faster (27s -> 19s in one
benchmark, and there is a lot of room for further
optimization).

We now tokenize the input text, then parse the token stream.

Macros modify the token stream, so they should now be effective
in any context, including math. Thus, we no longer need the clunky
macro processing capacities of texmath.

A custom state LaTeXState is used instead of ParserState.
This, plus the tokenization, will require some rewriting
of the exported functions rawLaTeXInline, inlineCommand,
rawLaTeXBlock.

* Added Text.Pandoc.Readers.LaTeX.Types (new exported module).
  Exports Macro, Tok, TokType, Line, Column.  [API change]
* Text.Pandoc.Parsing: adjusted type of `insertIncludedFile`
  so it can be used with token parser.
* Removed old texmath macro stuff from Parsing.
  Use Macro from Text.Pandoc.Readers.LaTeX.Types instead.
* Removed texmath macro material from Markdown reader.
* Changed types for Text.Pandoc.Readers.LaTeX's
  rawLaTeXInline and rawLaTeXBlock.  (Both now return a String,
  and they are polymorphic in state.)
* Added orgMacros field to OrgState.  [API change]
* Removed readerApplyMacros from ReaderOptions.
  Now we just check the `latex_macros` reader extension.
* Allow `\newcommand\foo{blah}` without braces.

Fixes #1390.
Fixes #2118.
Fixes #3236.
Fixes #3779.
Fixes #934.
Fixes #982.
2017-07-07 12:36:00 +02:00
..
command Rewrote LaTeX reader with proper tokenization. 2017-07-07 12:36:00 +02:00
docx Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
epub Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
fb2 Don't allow backslash + newline to affect block structure. 2017-06-11 22:24:20 +02:00
lua data/pandoc.lua: regularize constructors. 2017-06-29 17:08:59 +02:00
media Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
odt Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
Tests Rewrote LaTeX reader with proper tokenization. 2017-07-07 12:36:00 +02:00
bodybg.gif Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
docbook-reader.docbook Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
docbook-reader.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
docbook-xref.docbook Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
docbook-xref.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
dokuwiki_external_images.dokuwiki Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
dokuwiki_external_images.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
dokuwiki_inline_formatting.dokuwiki Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
dokuwiki_inline_formatting.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
dokuwiki_multiblock_table.dokuwiki Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
dokuwiki_multiblock_table.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
haddock-reader.haddock Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
haddock-reader.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
html-reader.html Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
html-reader.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
insert Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
lalune.jpg Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
latex-reader.latex Rewrote LaTeX reader with proper tokenization. 2017-07-07 12:36:00 +02:00
latex-reader.native Rewrote LaTeX reader with proper tokenization. 2017-07-07 12:36:00 +02:00
lhs-test-markdown.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
lhs-test.fragment.html+lhs Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
lhs-test.html HTML line block: Use class instead of style attribute. 2017-04-25 23:07:30 +02:00
lhs-test.html+lhs HTML line block: Use class instead of style attribute. 2017-04-25 23:07:30 +02:00
lhs-test.latex LaTeX: Load parskip before hyperref. (#3654) 2017-05-09 22:09:10 +02:00
lhs-test.latex+lhs LaTeX: Load parskip before hyperref. (#3654) 2017-05-09 22:09:10 +02:00
lhs-test.markdown Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
lhs-test.markdown+lhs Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
lhs-test.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
lhs-test.rst Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
lhs-test.rst+lhs Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
markdown-citations.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
markdown-citations.txt Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
markdown-reader-more.native Rewrote LaTeX reader with proper tokenization. 2017-07-07 12:36:00 +02:00
markdown-reader-more.txt Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
mediawiki-reader.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
mediawiki-reader.wiki Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
movie.jpg Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
opml-reader.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
opml-reader.opml Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
pipe-tables.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
pipe-tables.txt Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
rst-reader.native RST reader: support scale and align attributes of images. 2017-02-26 23:40:31 +01:00
rst-reader.rst Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
s5-basic.html HTML line block: Use class instead of style attribute. 2017-04-25 23:07:30 +02:00
s5-fancy.html HTML line block: Use class instead of style attribute. 2017-04-25 23:07:30 +02:00
s5-fragment.html Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
s5-inserts.html HTML line block: Use class instead of style attribute. 2017-04-25 23:07:30 +02:00
s5.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables-rstsubset.native Combine grid table parsers 2017-05-11 00:17:56 +02:00
tables.asciidoc Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.context Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.docbook4 Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.docbook5 Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.dokuwiki Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.fb2 Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.haddock Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.html4 Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.html5 Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.icml Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.jats JATS writer: put references in <back>. 2017-03-31 11:07:09 +02:00
tables.latex Updated table tests. 2017-02-23 22:34:10 +01:00
tables.man Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.markdown Markdown writer: Avoid spurious blanklines at end of document... 2017-03-08 12:47:39 +01:00
tables.mediawiki Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.ms Ms writer: respect text wrapping options. 2017-04-05 15:17:35 +02:00
tables.muse Muse writer: Indent tables with one space (#3649) 2017-05-07 21:41:38 +02:00
tables.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.opendocument Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.org Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.plain Markdown writer: Avoid spurious blanklines at end of document... 2017-03-08 12:47:39 +01:00
tables.rst Grid tables: remove unnecessary extra space in cells. 2017-03-23 14:59:51 +01:00
tables.rtf Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.tei Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.texinfo Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.textile Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.txt Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
tables.zimwiki ZimWiki writer: removed internal formatting from note and table cells, because ZimWiki does not support it (#3446) 2017-02-15 11:28:02 +01:00
test-pandoc.hs Add Muse reader (#3620) 2017-06-19 10:46:02 +02:00
testsuite.native Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
testsuite.txt Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
textile-reader.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
textile-reader.textile Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
twiki-reader.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
twiki-reader.twiki Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
txt2tags.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
txt2tags.t2t Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00
vimwiki-reader.native Added Vimwiki reader (#3705). 2017-06-19 22:15:12 +02:00
vimwiki-reader.wiki Added Vimwiki reader (#3705). 2017-06-19 22:15:12 +02:00
writer.asciidoc Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.context Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.docbook4 Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.docbook5 Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.dokuwiki Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.fb2 Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.haddock Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.html4 Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.html5 Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.icml Allow em for image height/width in HTML, LaTeX. 2017-05-25 22:48:27 +02:00
writer.jats Updated jats tests for new texmath version. 2017-06-30 20:50:37 +02:00
writer.latex Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.man Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.markdown Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.mediawiki Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.ms Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.muse Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.native Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.opendocument Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.opml Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.org Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.plain Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.rst Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.rtf Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.tei Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.texinfo Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.textile Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writer.zimwiki Added spaced_reference_links extension. 2017-05-25 12:57:31 +02:00
writers-lang-and-dir.context ConTeXt template: improved font handling. 2017-05-06 14:58:32 +02:00
writers-lang-and-dir.latex Test updates for latex template changes. 2017-05-18 22:46:58 +02:00
writers-lang-and-dir.native Moved tests/ -> test/. 2017-02-04 12:56:30 +01:00