Repository : ssh://[email protected]/Cabal

On branch  : ghc-head
Link       : 
http://git.haskell.org/?p=packages/Cabal.git;a=commit;h=e409c80f1d97af2821422f4d5e830534fb16ee95

>---------------------------------------------------------------

commit e409c80f1d97af2821422f4d5e830534fb16ee95
Author: Herbert Valerio Riedel <[email protected]>
Date:   Fri Sep 13 11:22:58 2013 +0200

    Support non-orphaned `instance Data Version` in GHC≥7.7
    
    Signed-off-by: Herbert Valerio Riedel <[email protected]>
    (cherry picked from commit c8299265457197e11184998cffc19596d5116186)


>---------------------------------------------------------------

e409c80f1d97af2821422f4d5e830534fb16ee95
 Cabal/Distribution/Version.hs |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/Cabal/Distribution/Version.hs b/Cabal/Distribution/Version.hs
index ca93319..feb3146 100644
--- a/Cabal/Distribution/Version.hs
+++ b/Cabal/Distribution/Version.hs
@@ -1,4 +1,4 @@
-{-# LANGUAGE DeriveDataTypeable, StandaloneDeriving #-}
+{-# LANGUAGE CPP, DeriveDataTypeable, StandaloneDeriving #-}
 -----------------------------------------------------------------------------
 -- |
 -- Module      :  Distribution.Version
@@ -121,8 +121,10 @@ data VersionRange
   | VersionRangeParens     VersionRange -- just '(exp)' parentheses syntax
   deriving (Show,Read,Eq,Typeable,Data)
 
--- TODO orphan
+#if __GLASGOW_HASKELL__ < 707
+-- starting with ghc-7.7/base-4.7 this instance is provided in "Data.Data"
 deriving instance Data Version
+#endif
 
 {-# DEPRECATED AnyVersion "Use 'anyVersion', 'foldVersionRange' or 
'asVersionIntervals'" #-}
 {-# DEPRECATED ThisVersion "use 'thisVersion', 'foldVersionRange' or 
'asVersionIntervals'" #-}

_______________________________________________
ghc-commits mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/ghc-commits

Reply via email to