From c38f8264355ebf99c2e1594279120d4fbdb0efc1 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sat, 28 May 2011 11:56:48 -0400 Subject: [PATCH] Data.Tuple.swap not available with ghc 6.12.3 --- Command/Status.hs | 2 +- .../build_issue_with_latest_release_0.20110522-1-gde817ba.mdwn | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Command/Status.hs b/Command/Status.hs index 43a9484433..dd518416cf 100644 --- a/Command/Status.hs +++ b/Command/Status.hs @@ -11,7 +11,6 @@ import Control.Monad.State import Data.Maybe import System.IO import Data.List -import Data.Tuple import qualified Data.Map as M import qualified Annex @@ -134,6 +133,7 @@ backend_usage = stat "backend usage" $ splits :: [Key] -> [(String, Integer)] splits ks = M.toList $ M.fromListWith (+) $ map tcount ks tcount k = (keyBackendName k, 1) + swap (a, b) = (b, a) pp c [] = c pp c ((n, b):xs) = "\n\t" ++ b ++ ": " ++ show n ++ pp c xs diff --git a/doc/bugs/build_issue_with_latest_release_0.20110522-1-gde817ba.mdwn b/doc/bugs/build_issue_with_latest_release_0.20110522-1-gde817ba.mdwn index c5fddd63c6..a7bae50b8b 100644 --- a/doc/bugs/build_issue_with_latest_release_0.20110522-1-gde817ba.mdwn +++ b/doc/bugs/build_issue_with_latest_release_0.20110522-1-gde817ba.mdwn @@ -9,3 +9,6 @@ make: *** [git-annex] Error 1 it fails on OSX 10.6.x with ghc 6.12.3 and a corresponding haskell-platform install. I ran a bisect and found that commit 75a3f5027f74565d909fb940893636d081d9872a seems to have broken git-annex for me, reverting the commit allows me to build git-annex, I have not run the tests to verify everything is working correctly though. + +> Probably `swap` appeared only in a newer GHC. I've reverted to avoid a +> versioned build dependency. [[done]] --[[Joey]]