git.iko.soy/typeable/pandoc
on master help sign in
Allow earlier versions of haddock-library, use CPP.
fad8d0dJohn MacFarlane
pandoc.cabal+1−1
@@ -388,7 +388,7 @@ library
388 hslua-module-text >= 0.1.2 && < 0.2,
388 hslua-module-text >= 0.1.2 && < 0.2,
389 binary >= 0.5 && < 0.10,
389 binary >= 0.5 && < 0.10,
390 SHA >= 1.6 && < 1.7,
390 SHA >= 1.6 && < 1.7,
391− haddock-library >= 1.5 && < 1.6,
391+ haddock-library >= 1.1 && < 1.6,
392 deepseq >= 1.3 && < 1.5,
392 deepseq >= 1.3 && < 1.5,
393 JuicyPixels >= 3.1.6.1 && < 3.3,
393 JuicyPixels >= 3.1.6.1 && < 3.3,
394 Glob >= 0.7 && < 0.10,
394 Glob >= 0.7 && < 0.10,
src/Text/Pandoc/Readers/Haddock.hs+2
@@ -85,6 +85,7 @@ docHToBlocks d' =
85 DocProperty s -> B.codeBlockWith ("",["property","haskell"],[]) (trim s)
85 DocProperty s -> B.codeBlockWith ("",["property","haskell"],[]) (trim s)
86 DocExamples es -> mconcat $ map (\e ->
86 DocExamples es -> mconcat $ map (\e ->
87 makeExample ">>>" (exampleExpression e) (exampleResult e)) es
87 makeExample ">>>" (exampleExpression e) (exampleResult e)) es
88+#if MIN_VERSION_haddock_library(1,5,0)
88 DocTable H.Table{ tableHeaderRows = headerRows
89 DocTable H.Table{ tableHeaderRows = headerRows
89 , tableBodyRows = bodyRows
90 , tableBodyRows = bodyRows
90 }
91 }
@@ -97,6 +98,7 @@ docHToBlocks d' =
97 colspecs = replicate (maximum (map length body))
98 colspecs = replicate (maximum (map length body))
98 (AlignDefault, 0.0)
99 (AlignDefault, 0.0)
99 in B.table mempty colspecs header body
100 in B.table mempty colspecs header body
101+#endif
100
102
101 where inlineFallback = B.plain $ docHToInlines False d'
103 where inlineFallback = B.plain $ docHToInlines False d'
102 consolidatePlains = B.fromList . consolidatePlains' . B.toList
104 consolidatePlains = B.fromList . consolidatePlains' . B.toList