aboutsummaryrefslogtreecommitdiff
path: root/Utils.hs
diff options
context:
space:
mode:
authorMirek Kratochvil <exa.exa@gmail.com>2023-05-25 00:08:10 +0200
committerMirek Kratochvil <exa.exa@gmail.com>2023-05-25 00:10:49 +0200
commit32e050bac753687b801a40c91e398a0132ccffbc (patch)
tree1bdd712879147d52e9fb7d25926d05da50f83a0e /Utils.hs
parent98c38296e0ef543074b4cfb352e364903f7898ef (diff)
downloadreploy-32e050bac753687b801a40c91e398a0132ccffbc.tar.gz
reploy-32e050bac753687b801a40c91e398a0132ccffbc.tar.bz2
tags get sourced
Diffstat (limited to 'Utils.hs')
-rw-r--r--Utils.hs4
1 files changed, 4 insertions, 0 deletions
diff --git a/Utils.hs b/Utils.hs
index 2650d2e..c609262 100644
--- a/Utils.hs
+++ b/Utils.hs
@@ -16,3 +16,7 @@ just err Nothing = error ("Missing: " ++ err)
-- | Test for whether something listy has a suffix
hasSuffix :: Eq a => [a] -> [a] -> Bool
hasSuffix s = isJust . stripSuffix s
+
+-- | The same second as from arrows et al.
+second :: (a -> b) -> (c, a) -> (c, b)
+second f (a, b) = (a, f b)