[commit: ghc] wip/nfs-locking: Clean up Base. (9bde7d8)
git at git.haskell.org
git at git.haskell.org
Thu Oct 26 23:12:57 UTC 2017
Repository : ssh://git@git.haskell.org/ghc
On branch : wip/nfs-locking
Link : http://ghc.haskell.org/trac/ghc/changeset/9bde7d8668019ed08561c701e3f2ba61ac173d6e/ghc
>---------------------------------------------------------------
commit 9bde7d8668019ed08561c701e3f2ba61ac173d6e
Author: Andrey Mokhov <andrey.mokhov at gmail.com>
Date: Tue Jul 14 23:49:13 2015 +0100
Clean up Base.
>---------------------------------------------------------------
9bde7d8668019ed08561c701e3f2ba61ac173d6e
src/Base.hs | 13 -------------
1 file changed, 13 deletions(-)
diff --git a/src/Base.hs b/src/Base.hs
index 026f211..97a22d5 100644
--- a/src/Base.hs
+++ b/src/Base.hs
@@ -10,7 +10,6 @@ module Base (
Stage (..),
Arg, ArgList,
ShowArg (..), ShowArgs (..),
- filterOut,
productArgs, concatArgs
) where
@@ -56,21 +55,9 @@ class ShowArgs a where
instance ShowArgs [String] where
showArgs = return
-instance ShowArgs [Arg] where
- showArgs = sequence
-
-instance ShowArgs [ArgList] where
- showArgs = mconcat
-
instance ShowArgs a => ShowArgs (Action a) where
showArgs = (showArgs =<<)
--- Filter out given arg(s) from a collection
-filterOut :: ShowArgs a => ArgList -> a -> ArgList
-filterOut as exclude = do
- exclude' <- showArgs exclude
- filter (`notElem` exclude') <$> as
-
-- Generate a cross product collection of two argument collections
-- Example: productArgs ["-a", "-b"] "c" = args ["-a", "c", "-b", "c"]
productArgs :: (ShowArgs a, ShowArgs b) => a -> b -> ArgList
More information about the ghc-commits
mailing list