git.iko.soy/typeable/pandoc
on master help sign in
Allow earlier versions of haddock-library, use CPP.
commitfad8d0d67ff4736e1af554d2bfcf1688aa28c8ec authorJohn MacFarlane <jgm@berkeley.edu> dateFri 16 Mar 2018, 23:18 (9 years ago) parentbe12ae3
2 files changed+3−1
pandoc.cabal+1−1 src/Text/Pandoc/Readers/Haddock.hs+2
pandoc.cabal+1−1
@@ -388,7 +388,7 @@ library
388388 hslua-module-text >= 0.1.2 && < 0.2,
389389 binary >= 0.5 && < 0.10,
390390 SHA >= 1.6 && < 1.7,
391− haddock-library >= 1.5 && < 1.6,
391+ haddock-library >= 1.1 && < 1.6,
392392 deepseq >= 1.3 && < 1.5,
393393 JuicyPixels >= 3.1.6.1 && < 3.3,
394394 Glob >= 0.7 && < 0.10,
src/Text/Pandoc/Readers/Haddock.hs+2
@@ -85,6 +85,7 @@ docHToBlocks d' =
8585 DocProperty s -> B.codeBlockWith ("",["property","haskell"],[]) (trim s)
8686 DocExamples es -> mconcat $ map (\e ->
8787 makeExample ">>>" (exampleExpression e) (exampleResult e)) es
88+#if MIN_VERSION_haddock_library(1,5,0)
8889 DocTable H.Table{ tableHeaderRows = headerRows
8990 , tableBodyRows = bodyRows
9091 }
@@ -97,6 +98,7 @@ docHToBlocks d' =
9798 colspecs = replicate (maximum (map length body))
9899 (AlignDefault, 0.0)
99100 in B.table mempty colspecs header body
101+#endif
100102
101103 where inlineFallback = B.plain $ docHToInlines False d'
102104 consolidatePlains = B.fromList . consolidatePlains' . B.toList