From 69e59e7f293b6107b5b722f330ba8c4ffcf6bbe5 Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Thu, 23 Jun 2016 23:04:42 -0700 Subject: Process markdown extensions on command line in L->R order. Previously they were processed, very unintuitively, in R->L order, so that `markdown-tex_math_dollars+tex_math_dollars` had `tex_math_dollars` disabled. Closes #2995. --- src/Text/Pandoc.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/Text/Pandoc.hs b/src/Text/Pandoc.hs index 0330c46e2..cd93e0b7b 100644 --- a/src/Text/Pandoc.hs +++ b/src/Text/Pandoc.hs @@ -191,7 +191,7 @@ parseFormatSpec = parse formatSpec "" where formatSpec = do name <- formatName extMods <- many extMod - return (name, foldl (.) id extMods) + return (name, \x -> foldl (flip ($)) x extMods) formatName = many1 $ noneOf "-+" extMod = do polarity <- oneOf "-+" -- cgit v1.2.3