aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2015-03-19 11:48:05 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2015-03-19 11:48:05 -0700
commitb983adf0d0cbc98d2da1e2751f46ae1f93352be6 (patch)
tree859e222001a713c96591c9bbd17d6194e15c7730 /src/Text/Pandoc
parent8b8a613cd40ab61beb79beaf96d72be61890cef4 (diff)
downloadpandoc-b983adf0d0cbc98d2da1e2751f46ae1f93352be6.tar.gz
Markdown writer: fixes for GHC 7.10.
Diffstat (limited to 'src/Text/Pandoc')
-rw-r--r--src/Text/Pandoc/Writers/Markdown.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Text/Pandoc/Writers/Markdown.hs b/src/Text/Pandoc/Writers/Markdown.hs
index ebf7e20e2..dee4d56a4 100644
--- a/src/Text/Pandoc/Writers/Markdown.hs
+++ b/src/Text/Pandoc/Writers/Markdown.hs
@@ -724,9 +724,9 @@ avoidBadWrapsInList [] = []
avoidBadWrapsInList (Space:Str ('>':cs):xs) =
Str (' ':'>':cs) : avoidBadWrapsInList xs
avoidBadWrapsInList (Space:Str [c]:[])
- | c `elem` "-*+" = Str [' ', c] : []
+ | c `elem` ['-','*','+'] = Str [' ', c] : []
avoidBadWrapsInList (Space:Str [c]:Space:xs)
- | c `elem` "-*+" = Str [' ', c] : Space : avoidBadWrapsInList xs
+ | c `elem` ['-','*','+'] = Str [' ', c] : Space : avoidBadWrapsInList xs
avoidBadWrapsInList (Space:Str cs:Space:xs)
| isOrderedListMarker cs = Str (' ':cs) : Space : avoidBadWrapsInList xs
avoidBadWrapsInList (Space:Str cs:[])
@@ -734,7 +734,7 @@ avoidBadWrapsInList (Space:Str cs:[])
avoidBadWrapsInList (x:xs) = x : avoidBadWrapsInList xs
isOrderedListMarker :: String -> Bool
-isOrderedListMarker xs = (last xs `elem` ".)") &&
+isOrderedListMarker xs = (last xs `elem` ['.',')']) &&
isRight (runParserT (anyOrderedListMarker >> eof)
defaultParserState "" xs)