diff options
author | John MacFarlane <jgm@berkeley.edu> | 2017-06-10 23:39:49 +0200 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2017-06-11 00:46:31 +0200 |
commit | fa719d026464619dd51714620470998ab5d18e17 (patch) | |
tree | 9eb4eeaff01a2c6f3ccb283ff57d07ef5f622beb /trypandoc | |
parent | 0c2a509dfb3bd9f7ba8a0fdec02a165ed7cf49da (diff) | |
download | pandoc-fa719d026464619dd51714620470998ab5d18e17.tar.gz |
Switched Writer types to use Text.
* XML.toEntities: changed type to Text -> Text.
* Shared.tabFilter -- fixed so it strips out CRs as before.
* Modified writers to take Text.
* Updated tests, benchmarks, trypandoc.
[API change]
Closes #3731.
Diffstat (limited to 'trypandoc')
-rw-r--r-- | trypandoc/trypandoc.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/trypandoc/trypandoc.hs b/trypandoc/trypandoc.hs index 0dd88a61f..d8652079a 100644 --- a/trypandoc/trypandoc.hs +++ b/trypandoc/trypandoc.hs @@ -33,11 +33,11 @@ app req respond = do _ -> error $ "could not find reader for " ++ T.unpack fromFormat let writer = case getWriter (T.unpack toFormat) of - Right (StringWriter w) -> w writerOpts + Right (TextWriter w) -> w writerOpts _ -> error $ "could not find writer for " ++ T.unpack toFormat let result = case runPure $ reader (tabFilter 4 text) >>= writer of - Right s -> T.pack s + Right s -> s Left err -> error (show err) let output = encode $ object [ T.pack "html" .= result , T.pack "name" .= |