aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohn MacFarlane <[email protected]>2025-09-18 11:23:47 +0200
committerJohn MacFarlane <[email protected]>2025-09-18 11:23:47 +0200
commit4f2a383f499d2401b1ec6948423738941862e46e (patch)
treeb443ec13c8094ca6a7dc3008c402439a27a07e1c /src
parentbecb9a0a811e81592e5078c4de8da8bf6cfaca6a (diff)
RST reader: SkippedContent warning if table directive...
containts non-tabular content.
Diffstat (limited to 'src')
-rw-r--r--src/Text/Pandoc/Readers/RST.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/RST.hs b/src/Text/Pandoc/Readers/RST.hs
index 2ef7187b1..07fcbb476 100644
--- a/src/Text/Pandoc/Readers/RST.hs
+++ b/src/Text/Pandoc/Readers/RST.hs
@@ -912,7 +912,10 @@ tableDirective top fields body = do
let tspecs = zip aligns' widths
return $ B.singleton $ Table attr (B.caption Nothing (B.plain title))
tspecs thead tbody tfoot
- _ -> return mempty
+ _ -> do
+ pos <- getPosition
+ logMessage $ SkippedContent body pos
+ return mempty
where
-- only valid on the very first row of a table section
rowLength (Row _ rb) = sum $ cellLength <$> rb