diff options
author | Mark Wright <gienah@gentoo.org> | 2015-01-05 14:46:40 +1100 |
---|---|---|
committer | Mark Wright <gienah@gentoo.org> | 2015-01-05 14:46:40 +1100 |
commit | c80c9ac9dab01ea3e886b58dd500b3d2b83ff4fd (patch) | |
tree | de129fbdc01055141696d0811d504d10bd9969b7 /src/Text/Pandoc | |
parent | 8b9bded796b76a3f343c4cc1b8bb04a4b293ff55 (diff) | |
download | pandoc-c80c9ac9dab01ea3e886b58dd500b3d2b83ff4fd.tar.gz |
ghc 7.10.1 RC1 requires specifying the type of String literals https://ghc.haskell.org/trac/ghc/wiki/Migration/7.10#GHCsaysNoinstanceforFoldable...arisingfromtheuseof...
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r-- | src/Text/Pandoc/Writers/Markdown.hs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/Text/Pandoc/Writers/Markdown.hs b/src/Text/Pandoc/Writers/Markdown.hs index f06f1d6cc..d71f0daf8 100644 --- a/src/Text/Pandoc/Writers/Markdown.hs +++ b/src/Text/Pandoc/Writers/Markdown.hs @@ -323,9 +323,9 @@ blockToMarkdown opts (Plain inlines) = do then Just $ writerColumns opts else Nothing let rendered = render colwidth contents - let escapeDelimiter (x:xs) | x `elem` ".()" = '\\':x:xs - | otherwise = x : escapeDelimiter xs - escapeDelimiter [] = [] + let escapeDelimiter (x:xs) | x `elem` (".()" :: String) = '\\':x:xs + | otherwise = x : escapeDelimiter xs + escapeDelimiter [] = [] let contents' = if isEnabled Ext_all_symbols_escapable opts && not (stPlain st) && beginsWithOrderedListMarker rendered then text $ escapeDelimiter rendered @@ -681,7 +681,7 @@ inlineListToMarkdown opts lst = mapM (inlineToMarkdown opts) (avoidBadWraps lst) >>= return . cat where avoidBadWraps [] = [] avoidBadWraps (Space:Str (c:cs):xs) - | c `elem` "-*+>" = Str (' ':c:cs) : avoidBadWraps xs + | c `elem` ("-*+>" :: String) = Str (' ':c:cs) : avoidBadWraps xs avoidBadWraps (x:xs) = x : avoidBadWraps xs escapeSpaces :: Inline -> Inline @@ -821,8 +821,8 @@ inlineToMarkdown opts (Cite (c:cs) lst) sdoc <- inlineListToMarkdown opts sinlines let k' = text (modekey m ++ "@" ++ k) r = case sinlines of - Str (y:_):_ | y `elem` ",;]@" -> k' <> sdoc - _ -> k' <+> sdoc + Str (y:_):_ | y `elem` (",;]@" :: String) -> k' <> sdoc + _ -> k' <+> sdoc return $ pdoc <+> r modekey SuppressAuthor = "-" modekey _ = "" |