summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJasper Van der Jeugt <jaspervdj@gmail.com>2011-01-17 10:03:26 +0100
committerJasper Van der Jeugt <jaspervdj@gmail.com>2011-01-17 10:03:26 +0100
commitd569ae515606d45b931201cc464fd49b111cb3c9 (patch)
tree169517fc7af252933db87a15c1f8dc0ac9e6b700
parentb867e6f2042b64ba6ca2a3471bb12923f7d37456 (diff)
downloadhakyll-d569ae515606d45b931201cc464fd49b111cb3c9.tar.gz
Add utility mapA function
-rw-r--r--src/Hakyll/Core/Util/Arrow.hs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/Hakyll/Core/Util/Arrow.hs b/src/Hakyll/Core/Util/Arrow.hs
index 1896e11..d97ba22 100644
--- a/src/Hakyll/Core/Util/Arrow.hs
+++ b/src/Hakyll/Core/Util/Arrow.hs
@@ -4,6 +4,7 @@ module Hakyll.Core.Util.Arrow
( constA
, sequenceA
, unitA
+ , mapA
) where
import Control.Arrow (Arrow, (&&&), arr, (>>^))
@@ -23,3 +24,8 @@ sequenceA = foldl reduce $ constA []
unitA :: Arrow a
=> a b ()
unitA = constA ()
+
+mapA :: Arrow a
+ => (b -> c)
+ -> a [b] [c]
+mapA = arr . map