aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Writers/Haddock.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Text/Pandoc/Writers/Haddock.hs')
-rw-r--r--src/Text/Pandoc/Writers/Haddock.hs8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/Text/Pandoc/Writers/Haddock.hs b/src/Text/Pandoc/Writers/Haddock.hs
index 4f79b6c4e..6330259b0 100644
--- a/src/Text/Pandoc/Writers/Haddock.hs
+++ b/src/Text/Pandoc/Writers/Haddock.hs
@@ -125,14 +125,12 @@ blockToHaddock _ (CodeBlock (_,_,_) str) =
blockToHaddock opts (BlockQuote blocks) =
blockListToHaddock opts blocks
blockToHaddock opts (Table _ blkCapt specs thead tbody tfoot) = do
- let (caption, aligns, widths, headers, rows) = toLegacyTable blkCapt specs thead tbody tfoot
- caption' <- inlineListToHaddock opts caption
+ let Caption _ caption = blkCapt
+ caption' <- blockListToHaddock opts caption
let caption'' = if null caption
then empty
else blankline <> caption' <> blankline
- tbl <- gridTable opts blockListToHaddock
- (all null headers) (map (const AlignDefault) aligns)
- widths headers rows
+ tbl <- gridTable opts blockListToHaddock specs thead tbody tfoot
return $ (tbl $$ blankline $$ caption'') $$ blankline
blockToHaddock opts (BulletList items) = do
contents <- mapM (bulletListItemToHaddock opts) items