Hello community,

here is the log from the commit of package ghc-generic-deriving for 
openSUSE:Factory checked in at 2017-04-29 10:53:15
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ghc-generic-deriving (Old)
 and      /work/SRC/openSUSE:Factory/.ghc-generic-deriving.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "ghc-generic-deriving"

Sat Apr 29 10:53:15 2017 rev:6 rq:491691 version:1.11.2

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/ghc-generic-deriving/ghc-generic-deriving.changes    
    2017-04-20 20:55:47.390901041 +0200
+++ 
/work/SRC/openSUSE:Factory/.ghc-generic-deriving.new/ghc-generic-deriving.changes
   2017-04-29 10:53:15.454488734 +0200
@@ -1,0 +2,5 @@
+Wed Apr 19 13:32:43 UTC 2017 - [email protected]
+
+- Update to version 1.11.2 with cabal2obs.
+
+-------------------------------------------------------------------

Old:
----
  generic-deriving-1.11.1.tar.gz
  generic-deriving.cabal

New:
----
  generic-deriving-1.11.2.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ ghc-generic-deriving.spec ++++++
--- /var/tmp/diff_new_pack.6GYgf6/_old  2017-04-29 10:53:16.110396075 +0200
+++ /var/tmp/diff_new_pack.6GYgf6/_new  2017-04-29 10:53:16.110396075 +0200
@@ -19,14 +19,13 @@
 %global pkg_name generic-deriving
 %bcond_with tests
 Name:           ghc-%{pkg_name}
-Version:        1.11.1
+Version:        1.11.2
 Release:        0
 Summary:        Generic programming library for generalised deriving
 License:        BSD-3-Clause
 Group:          Development/Languages/Other
 Url:            https://hackage.haskell.org/package/%{pkg_name}
 Source0:        
https://hackage.haskell.org/package/%{pkg_name}-%{version}/%{pkg_name}-%{version}.tar.gz
-Source1:        
https://hackage.haskell.org/package/%{pkg_name}-%{version}/revision/1.cabal#/%{pkg_name}.cabal
 BuildRequires:  ghc-Cabal-devel
 BuildRequires:  ghc-containers-devel
 BuildRequires:  ghc-rpm-macros
@@ -61,7 +60,6 @@
 
 %prep
 %setup -q -n %{pkg_name}-%{version}
-cp -p %{SOURCE1} %{pkg_name}.cabal
 
 %build
 %ghc_lib_build

++++++ generic-deriving-1.11.1.tar.gz -> generic-deriving-1.11.2.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/generic-deriving-1.11.1/CHANGELOG.md 
new/generic-deriving-1.11.2/CHANGELOG.md
--- old/generic-deriving-1.11.1/CHANGELOG.md    2016-09-11 01:52:12.000000000 
+0200
+++ new/generic-deriving-1.11.2/CHANGELOG.md    2017-04-10 15:13:29.000000000 
+0200
@@ -1,3 +1,9 @@
+# 1.11.2 [2017.04.10]
+* Add `GEq`, `GShow`, `GEnum`, and `GIx` instances for the new data types
+  in `Foreign.C.Types` (`CBool`) and `System.Posix.Types` (`CBlkSize`,
+  `CBlkCnt`, `CClockId`, `CFsBlkCnt`, `CFsFilCnt`, `CId`, `CKey`, and `CTimer`)
+  introduced in `base-4.10.0.0`
+
 # 1.11.1 [2016.09.10]
 * Fix Template Haskell regression involving data families
 * Convert examples to test suite
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/generic-deriving-1.11.1/generic-deriving.cabal 
new/generic-deriving-1.11.2/generic-deriving.cabal
--- old/generic-deriving-1.11.1/generic-deriving.cabal  2016-09-11 
01:52:12.000000000 +0200
+++ new/generic-deriving-1.11.2/generic-deriving.cabal  2017-04-10 
15:13:29.000000000 +0200
@@ -1,5 +1,5 @@
 name:                   generic-deriving
-version:                1.11.1
+version:                1.11.2
 synopsis:               Generic programming library for generalised deriving.
 description:
 
@@ -31,7 +31,8 @@
                       , GHC == 7.6.3
                       , GHC == 7.8.4
                       , GHC == 7.10.3
-                      , GHC == 8.0.1
+                      , GHC == 8.0.2
+                      , GHC == 8.2.1
 extra-source-files:     CHANGELOG.md
                       , README.md
 
@@ -75,7 +76,7 @@
 
   build-depends:        containers       >= 0.1 && < 0.6
                       , ghc-prim                   < 1
-                      , template-haskell >= 2.4 && < 2.12
+                      , template-haskell >= 2.4 && < 2.13
 
   default-language:     Haskell2010
   ghc-options:          -Wall
@@ -86,9 +87,9 @@
   other-modules:        ExampleSpec
                         TypeInTypeSpec
   build-depends:        base             >= 4.3  && < 5
-                      , generic-deriving == 1.11.1
+                      , generic-deriving
                       , hspec            >= 2    && < 3
-                      , template-haskell >= 2.4  && < 2.12
+                      , template-haskell >= 2.4  && < 2.13
   hs-source-dirs:       tests
   default-language:     Haskell2010
   ghc-options:          -Wall -threaded -rtsopts
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/generic-deriving-1.11.1/src/Generics/Deriving/Enum.hs 
new/generic-deriving-1.11.2/src/Generics/Deriving/Enum.hs
--- old/generic-deriving-1.11.1/src/Generics/Deriving/Enum.hs   2016-09-11 
01:52:11.000000000 +0200
+++ new/generic-deriving-1.11.2/src/Generics/Deriving/Enum.hs   2017-04-10 
15:13:29.000000000 +0200
@@ -537,6 +537,46 @@
 instance GEnum a => GEnum (ZipList a) where
   genum = genumDefault
 
+#if MIN_VERSION_base(4,10,0)
+instance GEnum CBool where
+  genum = coerce (genum :: [HTYPE_BOOL])
+
+# if defined(HTYPE_BLKSIZE_T)
+instance GEnum CBlkSize where
+  genum = coerce (genum :: [HTYPE_BLKSIZE_T])
+# endif
+
+# if defined(HTYPE_BLKCNT_T)
+instance GEnum CBlkCnt where
+  genum = coerce (genum :: [HTYPE_BLKCNT_T])
+# endif
+
+# if defined(HTYPE_CLOCKID_T)
+instance GEnum CClockId where
+  genum = coerce (genum :: [HTYPE_CLOCKID_T])
+# endif
+
+# if defined(HTYPE_FSBLKCNT_T)
+instance GEnum CFsBlkCnt where
+  genum = coerce (genum :: [HTYPE_FSBLKCNT_T])
+# endif
+
+# if defined(HTYPE_FSFILCNT_T)
+instance GEnum CFsFilCnt where
+  genum = coerce (genum :: [HTYPE_FSFILCNT_T])
+# endif
+
+# if defined(HTYPE_ID_T)
+instance GEnum CId where
+  genum = coerce (genum :: [HTYPE_ID_T])
+# endif
+
+# if defined(HTYPE_KEY_T)
+instance GEnum CKey where
+  genum = coerce (genum :: [HTYPE_KEY_T])
+# endif
+#endif
+
 
--------------------------------------------------------------------------------
 -- Generic Ix
 
--------------------------------------------------------------------------------
@@ -1052,3 +1092,59 @@
   index   = indexDefault
   inRange = inRangeDefault
 #endif
+
+#if MIN_VERSION_base(4,10,0)
+instance GIx CBool where
+  range   = rangeEnum
+  index   = indexIntegral
+  inRange = inRangeOrd
+
+# if defined(HTYPE_BLKSIZE_T)
+instance GIx CBlkSize where
+  range   = rangeEnum
+  index   = indexIntegral
+  inRange = inRangeOrd
+# endif
+
+# if defined(HTYPE_BLKCNT_T)
+instance GIx CBlkCnt where
+  range   = rangeEnum
+  index   = indexIntegral
+  inRange = inRangeOrd
+# endif
+
+# if defined(HTYPE_CLOCKID_T)
+instance GIx CClockId where
+  range   = rangeEnum
+  index   = indexIntegral
+  inRange = inRangeOrd
+# endif
+
+# if defined(HTYPE_FSBLKCNT_T)
+instance GIx CFsBlkCnt where
+  range   = rangeEnum
+  index   = indexIntegral
+  inRange = inRangeOrd
+# endif
+
+# if defined(HTYPE_FSFILCNT_T)
+instance GIx CFsFilCnt where
+  range   = rangeEnum
+  index   = indexIntegral
+  inRange = inRangeOrd
+# endif
+
+# if defined(HTYPE_ID_T)
+instance GIx CId where
+  range   = rangeEnum
+  index   = indexIntegral
+  inRange = inRangeOrd
+# endif
+
+# if defined(HTYPE_KEY_T)
+instance GIx CKey where
+  range   = rangeEnum
+  index   = indexIntegral
+  inRange = inRangeOrd
+# endif
+#endif
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/generic-deriving-1.11.1/src/Generics/Deriving/Eq.hs 
new/generic-deriving-1.11.2/src/Generics/Deriving/Eq.hs
--- old/generic-deriving-1.11.1/src/Generics/Deriving/Eq.hs     2016-09-11 
01:52:11.000000000 +0200
+++ new/generic-deriving-1.11.2/src/Generics/Deriving/Eq.hs     2017-04-10 
15:13:29.000000000 +0200
@@ -576,3 +576,48 @@
 
 instance GEq a => GEq (ZipList a) where
   geq = geqdefault
+
+#if MIN_VERSION_base(4,10,0)
+instance GEq CBool where
+  geq = (==)
+
+# if defined(HTYPE_BLKSIZE_T)
+instance GEq CBlkSize where
+  geq = (==)
+# endif
+
+# if defined(HTYPE_BLKCNT_T)
+instance GEq CBlkCnt where
+  geq = (==)
+# endif
+
+# if defined(HTYPE_CLOCKID_T)
+instance GEq CClockId where
+  geq = (==)
+# endif
+
+# if defined(HTYPE_FSBLKCNT_T)
+instance GEq CFsBlkCnt where
+  geq = (==)
+# endif
+
+# if defined(HTYPE_FSFILCNT_T)
+instance GEq CFsFilCnt where
+  geq = (==)
+# endif
+
+# if defined(HTYPE_ID_T)
+instance GEq CId where
+  geq = (==)
+# endif
+
+# if defined(HTYPE_KEY_T)
+instance GEq CKey where
+  geq = (==)
+# endif
+
+# if defined(HTYPE_TIMER_T)
+instance GEq CTimer where
+  geq = (==)
+# endif
+#endif
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/generic-deriving-1.11.1/src/Generics/Deriving/Show.hs 
new/generic-deriving-1.11.2/src/Generics/Deriving/Show.hs
--- old/generic-deriving-1.11.1/src/Generics/Deriving/Show.hs   2016-09-11 
01:52:11.000000000 +0200
+++ new/generic-deriving-1.11.2/src/Generics/Deriving/Show.hs   2017-04-10 
15:13:29.000000000 +0200
@@ -615,3 +615,48 @@
 
 instance GShow a => GShow (ZipList a) where
   gshowsPrec = gshowsPrecdefault
+
+#if MIN_VERSION_base(4,10,0)
+instance GShow CBool where
+  gshowsPrec = showsPrec
+
+# if defined(HTYPE_BLKSIZE_T)
+instance GShow CBlkSize where
+  gshowsPrec = showsPrec
+# endif
+
+# if defined(HTYPE_BLKCNT_T)
+instance GShow CBlkCnt where
+  gshowsPrec = showsPrec
+# endif
+
+# if defined(HTYPE_CLOCKID_T)
+instance GShow CClockId where
+  gshowsPrec = showsPrec
+# endif
+
+# if defined(HTYPE_FSBLKCNT_T)
+instance GShow CFsBlkCnt where
+  gshowsPrec = showsPrec
+# endif
+
+# if defined(HTYPE_FSFILCNT_T)
+instance GShow CFsFilCnt where
+  gshowsPrec = showsPrec
+# endif
+
+# if defined(HTYPE_ID_T)
+instance GShow CId where
+  gshowsPrec = showsPrec
+# endif
+
+# if defined(HTYPE_KEY_T)
+instance GShow CKey where
+  gshowsPrec = showsPrec
+# endif
+
+# if defined(HTYPE_TIMER_T)
+instance GShow CTimer where
+  gshowsPrec = showsPrec
+# endif
+#endif
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/generic-deriving-1.11.1/src/Generics/Deriving/TH/Internal.hs 
new/generic-deriving-1.11.2/src/Generics/Deriving/TH/Internal.hs
--- old/generic-deriving-1.11.1/src/Generics/Deriving/TH/Internal.hs    
2016-09-11 01:52:11.000000000 +0200
+++ new/generic-deriving-1.11.2/src/Generics/Deriving/TH/Internal.hs    
2017-04-10 15:13:29.000000000 +0200
@@ -536,8 +536,8 @@
                    case mbLastArgKindName of
                         Nothing   -> map tyVarBndrToType headRequiredTvbs
                         Just _lakn ->
--- See Note [Generic1 is polykinded on GHC 8.2] in Generics.Deriving.TH
-#if __GLASGOW_HASKELL__ >= 801
+-- See Note [Generic1 is polykinded in base-4.10] in Generics.Deriving.TH
+#if MIN_VERSION_base(4,10,0)
                           map tyVarBndrToType headRequiredTvbs
 #else
                           map (substNameWithKindStarInTyVarBndr _lakn)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/generic-deriving-1.11.1/src/Generics/Deriving/TH.hs 
new/generic-deriving-1.11.2/src/Generics/Deriving/TH.hs
--- old/generic-deriving-1.11.1/src/Generics/Deriving/TH.hs     2016-09-11 
01:52:11.000000000 +0200
+++ new/generic-deriving-1.11.2/src/Generics/Deriving/TH.hs     2017-04-10 
15:13:29.000000000 +0200
@@ -689,8 +689,8 @@
     t', t'' :: Type
     t' = case gk of
               Gen1 _ (Just _kvName) ->
--- See Note [Generic1 is polykinded on GHC 8.2]
-#if __GLASGOW_HASKELL__ >= 801
+-- See Note [Generic1 is polykinded in base-4.10]
+#if MIN_VERSION_base(4,10,0)
                 t
 #else
                 substNameWithKind _kvName starK t
@@ -1063,8 +1063,8 @@
 
         -- Substitute kind * for any dropped kind variables
     let varTysExpSubst :: [Type]
--- See Note [Generic1 is polykinded on GHC 8.2]
-#if __GLASGOW_HASKELL__ >= 801
+-- See Note [Generic1 is polykinded in base-4.10]
+#if MIN_VERSION_base(4,10,0)
         varTysExpSubst = varTysExp
 #else
         varTysExpSubst = map (substNamesWithKindStar droppedKindVarNames) 
varTysExp
@@ -1077,8 +1077,8 @@
         (remainingTysExpSubst, droppedTysExpSubst) =
           splitAt remainingLength varTysExpSubst
 
--- See Note [Generic1 is polykinded on GHC 8.2]
-#if __GLASGOW_HASKELL__ < 801
+-- See Note [Generic1 is polykinded in base-4.10]
+#if !(MIN_VERSION_base(4,10,0))
     -- If any of the dropped types were polykinded, ensure that there are of
     -- kind * after substituting * for the dropped kind variables. If not,
     -- throw an error.
@@ -1104,8 +1104,8 @@
         --   instance C (Fam [Char])
     let varTysOrigSubst :: [Type]
         varTysOrigSubst =
--- See Note [Generic1 is polykinded on GHC 8.2]
-#if __GLASGOW_HASKELL__ >= 801
+-- See Note [Generic1 is polykinded in base-4.10]
+#if MIN_VERSION_base(4,10,0)
           id
 #else
           map (substNamesWithKindStar droppedKindVarNames)
@@ -1185,7 +1185,7 @@
 
 Then k gets specialized to *, which means that k should NOT show up in the RHS 
of
 a Rep1 type instance! To avoid this, make sure to substitute k with *.
-See also Note [Generic1 is polykinded on GHC 8.2].
+See also Note [Generic1 is polykinded in base-4.10].
 
 Note [Arguments to generated type synonyms]
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -1314,10 +1314,10 @@
 explicit kind signatures, leaving it up to GHC's kind inference machinery to
 figure out the correct kinds.
 
-Note [Generic1 is polykinded on GHC 8.2]
+Note [Generic1 is polykinded in base-4.10]
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
-Prior to GHC 8.2, Generic1 :: (* -> *) -> Constraint. This means that if a 
Generic1
+Prior to base-4.10, Generic1 :: (* -> *) -> Constraint. This means that if a 
Generic1
 instance is defined for a polykinded data type like so:
 
   data Proxy k (a :: k) = Proxy
@@ -1329,6 +1329,6 @@
 We must take great care to ensure that all occurrences of k are substituted 
with *,
 or else the generated instance will be ill kinded.
 
-On GHC 8.2 and later, Generic1 :: (k -> *) -> Constraint. This means we don't 
have
-to do this kind unification anymore! Hooray!
+In base-4.10 and later, Generic1 :: (k -> *) -> Constraint. This means we 
don't have
+to do any of this kind unification trickery anymore! Hooray!
 -}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/generic-deriving-1.11.1/tests/TypeInTypeSpec.hs 
new/generic-deriving-1.11.2/tests/TypeInTypeSpec.hs
--- old/generic-deriving-1.11.1/tests/TypeInTypeSpec.hs 2016-09-11 
01:52:11.000000000 +0200
+++ new/generic-deriving-1.11.2/tests/TypeInTypeSpec.hs 2017-04-10 
15:13:29.000000000 +0200
@@ -12,19 +12,42 @@
 import Test.Hspec
 
 #if __GLASGOW_HASKELL__ >= 800
-import Data.Proxy (Proxy)
+import Data.Proxy (Proxy(..))
 import Generics.Deriving.TH
 
+# if MIN_VERSION_base(4,10,0)
+import Generics.Deriving (Generic1(..))
+# endif
+
 data TyCon x (a :: x) (b :: k) = TyCon k x (Proxy a) (TyCon x a b)
 $(deriveAll0And1 ''TyCon)
 
 data family TyFam x (a :: x) (b :: k)
 data instance TyFam x (a :: x) (b :: k) = TyFam k x (Proxy a) (TyFam x a b)
 $(deriveAll0And1 'TyFam)
+
+# if MIN_VERSION_base(4,10,0)
+gen1PolyKinds :: Generic1 f => f 'True -> Rep1 f 'True
+gen1PolyKinds = from1
+# endif
 #endif
 
 main :: IO ()
 main = hspec spec
 
 spec :: Spec
-spec = return ()
+spec = parallel $ do
+#if MIN_VERSION_base(4,10,0)
+    describe "TyCon Bool 'False 'True" $
+      it "has an appropriately kinded Generic1 instance" $
+        let rep :: Rep1 (TyCon Bool 'False) 'True
+            rep = gen1PolyKinds $ let x = TyCon True False Proxy x in x
+         in seq rep () `shouldBe` ()
+    describe "TyFam Bool 'False 'True" $
+      it "has an appropriately kinded Generic1 instance" $
+        let rep :: Rep1 (TyFam Bool 'False) 'True
+            rep = gen1PolyKinds $ let x = TyFam True False Proxy x in x
+         in seq rep () `shouldBe` ()
+#else
+    return ()
+#endif


Reply via email to