aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Writers
diff options
context:
space:
mode:
Diffstat (limited to 'src/Text/Pandoc/Writers')
-rw-r--r--src/Text/Pandoc/Writers/Man.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Writers/Man.hs b/src/Text/Pandoc/Writers/Man.hs
index d2803f06f..645476b77 100644
--- a/src/Text/Pandoc/Writers/Man.hs
+++ b/src/Text/Pandoc/Writers/Man.hs
@@ -253,7 +253,9 @@ definitionListItemToMan opts (label, defs) = do
rest' <- liftM vcat $ mapM
(\item -> blockToMan opts item) xs
return $ first' $$
- text ".RS" $$ rest' $$ text ".RE"
+ if null xs
+ then empty
+ else text ".RS" $$ rest' $$ text ".RE"
[] -> return empty
return $ text ".TP" $$ nowrap (text ".B " <> labelText) $$ contents