From 6c32afc3c4c6b4d37759c2c197a6a3350c8f32d4 Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Tue, 14 Jul 2015 22:51:23 -0700 Subject: Updated to use cmark >= 0.4. --- src/Text/Pandoc/Writers/CommonMark.hs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/Text/Pandoc/Writers') diff --git a/src/Text/Pandoc/Writers/CommonMark.hs b/src/Text/Pandoc/Writers/CommonMark.hs index 61ac0fdba..fee36d454 100644 --- a/src/Text/Pandoc/Writers/CommonMark.hs +++ b/src/Text/Pandoc/Writers/CommonMark.hs @@ -76,8 +76,8 @@ blocksToCommonMark opts bs = return $ $ node DOCUMENT (blocksToNodes bs) where cmarkOpts = [optHardBreaks | isEnabled Ext_hard_line_breaks opts] colwidth = if writerWrapText opts - then writerColumns opts - else 0 + then Just $ writerColumns opts + else Nothing inlinesToCommonMark :: WriterOptions -> [Inline] -> Identity String inlinesToCommonMark opts ils = return $ @@ -85,8 +85,8 @@ inlinesToCommonMark opts ils = return $ $ node PARAGRAPH (inlinesToNodes ils) where cmarkOpts = [optHardBreaks | isEnabled Ext_hard_line_breaks opts] colwidth = if writerWrapText opts - then writerColumns opts - else 0 + then Just $ writerColumns opts + else Nothing blocksToNodes :: [Block] -> [Node] blocksToNodes = foldr blockToNodes [] -- cgit v1.2.3