Produce all DerivInfo in tcTyAndClassDecls
authorVladislav Zavialov <vlad.z.4096@gmail.com>
Fri, 28 Jun 2019 18:01:39 +0000 (21:01 +0300)
committerMarge Bot <ben+marge-bot@smart-cactus.org>
Fri, 5 Jul 2019 01:23:10 +0000 (21:23 -0400)
Before this refactoring:

* DerivInfo for data family instances was returned from tcTyAndClassDecls
* DerivInfo for data declarations was generated with mkDerivInfos and added at a
  later stage of the pipeline in tcInstDeclsDeriv

After this refactoring:

* DerivInfo for both data family instances and data declarations is returned from
  tcTyAndClassDecls in a single list.

This uniform treatment results in a more convenient arrangement to fix #16731.

compiler/typecheck/TcDeriv.hs
compiler/typecheck/TcInstDcls.hs
compiler/typecheck/TcRnDriver.hs
compiler/typecheck/TcTyClsDecls.hs
testsuite/tests/deriving/should_compile/T14578.stderr
testsuite/tests/deriving/should_compile/T14579.stderr
testsuite/tests/generics/GenDerivOutput.stderr
testsuite/tests/generics/GenDerivOutput1_1.stderr
testsuite/tests/generics/T10604/T10604_deriving.stderr

index b7c1478..224a6a7 100644 (file)
@@ -9,7 +9,7 @@ Handles @deriving@ clauses on @data@ declarations.
 {-# LANGUAGE CPP #-}
 {-# LANGUAGE TypeFamilies #-}
 
-module TcDeriv ( tcDeriving, DerivInfo(..), mkDerivInfos ) where
+module TcDeriv ( tcDeriving, DerivInfo(..) ) where
 
 #include "HsVersions.h"
 
@@ -23,7 +23,7 @@ import FamInst
 import TcDerivInfer
 import TcDerivUtils
 import TcValidity( allDistinctTyVars )
-import TcClassDcl( instDeclCtxt3, tcATDefault, tcMkDeclCtxt )
+import TcClassDcl( instDeclCtxt3, tcATDefault )
 import TcEnv
 import TcGenDeriv                       -- Deriv stuff
 import TcValidity( checkValidInstHead )
@@ -199,19 +199,6 @@ data DerivInfo = DerivInfo { di_rep_tc  :: TyCon
                            , di_ctxt    :: SDoc -- ^ error context
                            }
 
--- | Extract `deriving` clauses of proper data type (skips data families)
-mkDerivInfos :: [LTyClDecl GhcRn] -> TcM [DerivInfo]
-mkDerivInfos decls = concatMapM (mk_deriv . unLoc) decls
-  where
-
-    mk_deriv decl@(DataDecl { tcdLName = L _ data_name
-                            , tcdDataDefn =
-                                HsDataDefn { dd_derivs = L _ clauses } })
-      = do { tycon <- tcLookupTyCon data_name
-           ; return [DerivInfo { di_rep_tc = tycon, di_clauses = clauses
-                               , di_ctxt = tcMkDeclCtxt decl }] }
-    mk_deriv _ = return []
-
 {-
 
 ************************************************************************
index c2f7a11..716acb6 100644 (file)
@@ -392,17 +392,14 @@ tcInstDecls1 inst_decls
 --   (DerivDecl) to check and process all derived class instances.
 tcInstDeclsDeriv
   :: [DerivInfo]
-  -> [LTyClDecl GhcRn]
   -> [LDerivDecl GhcRn]
   -> TcM (TcGblEnv, [InstInfo GhcRn], HsValBinds GhcRn)
-tcInstDeclsDeriv datafam_deriv_infos tyclds derivds
+tcInstDeclsDeriv deriv_infos derivds
   = do th_stage <- getStage -- See Note [Deriving inside TH brackets]
        if isBrackStage th_stage
        then do { gbl_env <- getGblEnv
                ; return (gbl_env, bagToList emptyBag, emptyValBindsOut) }
-       else do { data_deriv_infos <- mkDerivInfos tyclds
-               ; let deriv_infos = datafam_deriv_infos ++ data_deriv_infos
-               ; (tcg_env, info_bag, valbinds) <- tcDeriving deriv_infos derivds
+       else do { (tcg_env, info_bag, valbinds) <- tcDeriving deriv_infos derivds
                ; return (tcg_env, bagToList info_bag, valbinds) }
 
 addClsInsts :: [InstInfo GhcRn] -> TcM a -> TcM a
index 55c2297..96240e6 100644 (file)
@@ -1682,7 +1682,7 @@ tcTyClsInstDecls :: [TyClGroup GhcRn]
 tcTyClsInstDecls tycl_decls deriv_decls binds
  = tcAddDataFamConPlaceholders (tycl_decls >>= group_instds) $
    tcAddPatSynPlaceholders (getPatSynBinds binds) $
-   do { (tcg_env, inst_info, datafam_deriv_info)
+   do { (tcg_env, inst_info, deriv_info)
           <- tcTyAndClassDecls tycl_decls ;
       ; setGblEnv tcg_env $ do {
           -- With the @TyClDecl@s and @InstDecl@s checked we're ready to
@@ -1692,9 +1692,8 @@ tcTyClsInstDecls tycl_decls deriv_decls binds
           -- Careful to quit now in case there were instance errors, so that
           -- the deriving errors don't pile up as well.
           ; failIfErrsM
-          ; let tyclds = tycl_decls >>= group_tyclds
           ; (tcg_env', inst_info', val_binds)
-              <- tcInstDeclsDeriv datafam_deriv_info tyclds deriv_decls
+              <- tcInstDeclsDeriv deriv_info deriv_decls
           ; setGblEnv tcg_env' $ do {
                 failIfErrsM
               ; pure (tcg_env', inst_info' ++ inst_info, val_binds)
index 06a7305..67fc558 100644 (file)
@@ -36,7 +36,7 @@ import TcHsSyn
 import TcTyDecls
 import TcClassDcl
 import {-# SOURCE #-} TcInstDcls( tcInstDecls1 )
-import TcDeriv (DerivInfo)
+import TcDeriv (DerivInfo(..))
 import TcUnify ( unifyKind )
 import TcHsType
 import ClsInst( AssocInstInfo(..) )
@@ -124,7 +124,7 @@ tcTyAndClassDecls :: [TyClGroup GhcRn]      -- Mutually-recursive groups in
                                             -- classes
                                             -- and their implicit Ids,DataCons
                          , [InstInfo GhcRn] -- Source-code instance decls info
-                         , [DerivInfo]      -- data family deriving info
+                         , [DerivInfo]      -- Deriving info
                          )
 -- Fails if there are any errors
 tcTyAndClassDecls tyclds_s
@@ -160,7 +160,7 @@ tcTyClGroup (TyClGroup { group_tyclds = tyclds
            -- Step 1: Typecheck the type/class declarations
        ; traceTc "---- tcTyClGroup ---- {" empty
        ; traceTc "Decls for" (ppr (map (tcdName . unLoc) tyclds))
-       ; tyclss <- tcTyClDecls tyclds role_annots
+       ; (tyclss, data_deriv_info) <- tcTyClDecls tyclds role_annots
 
            -- Step 1.5: Make sure we don't have any type synonym cycles
        ; traceTc "Starting synonym cycle check" (ppr tyclss)
@@ -186,12 +186,20 @@ tcTyClGroup (TyClGroup { group_tyclds = tyclds
        ; gbl_env <- addTyConsToGblEnv tyclss
 
            -- Step 4: check instance declarations
-       ; setGblEnv gbl_env $
-         tcInstDecls1 instds }
+       ; (gbl_env', inst_info, datafam_deriv_info) <-
+         setGblEnv gbl_env $
+         tcInstDecls1 instds
+
+       ; let deriv_info = datafam_deriv_info ++ data_deriv_info
+       ; return (gbl_env', inst_info, deriv_info) }
+
 
 tcTyClGroup (XTyClGroup _) = panic "tcTyClGroup"
 
-tcTyClDecls :: [LTyClDecl GhcRn] -> RoleAnnotEnv -> TcM [TyCon]
+tcTyClDecls
+  :: [LTyClDecl GhcRn]
+  -> RoleAnnotEnv
+  -> TcM ([TyCon], [DerivInfo])
 tcTyClDecls tyclds role_annots
   = tcExtendKindEnv promotion_err_env $   --- See Note [Type environment evolution]
     do {    -- Step 1: kind-check this group and returns the final
@@ -206,7 +214,7 @@ tcTyClDecls tyclds role_annots
             -- NB: We have to be careful here to NOT eagerly unfold
             -- type synonyms, as we have not tested for type synonym
             -- loops yet and could fall into a black hole.
-       ; fixM $ \ ~rec_tyclss -> do
+       ; fixM $ \ ~(rec_tyclss, _) -> do
            { tcg_env <- getGblEnv
            ; let roles = inferRoles (tcg_src tcg_env) role_annots rec_tyclss
 
@@ -214,7 +222,8 @@ tcTyClDecls tyclds role_annots
                  -- NB: if the decls mention any ill-staged data cons
                  -- (see Note [Recursion and promoting data constructors])
                  -- we will have failed already in kcTyClGroup, so no worries here
-           ; tcExtendRecEnv (zipRecTyClss tc_tycons rec_tyclss) $
+           ; (tycons, data_deriv_infos) <-
+             tcExtendRecEnv (zipRecTyClss tc_tycons rec_tyclss) $
 
                  -- Also extend the local type envt with bindings giving
                  -- a TcTyCon for each each knot-tied TyCon or Class
@@ -223,7 +232,8 @@ tcTyClDecls tyclds role_annots
              tcExtendKindEnvWithTyCons tc_tycons $
 
                  -- Kind and type check declarations for this group
-               mapM (tcTyClDecl roles) tyclds
+               mapAndUnzipM (tcTyClDecl roles) tyclds
+           ; return (tycons, concat data_deriv_infos)
            } }
   where
     promotion_err_env = mkPromotionErrorEnv tyclds
@@ -1521,40 +1531,55 @@ unlifted types, resolving #13595.
 
 -}
 
-tcTyClDecl :: RolesInfo -> LTyClDecl GhcRn -> TcM TyCon
+tcTyClDecl :: RolesInfo -> LTyClDecl GhcRn -> TcM (TyCon, [DerivInfo])
 tcTyClDecl roles_info (dL->L loc decl)
   | Just thing <- wiredInNameTyThing_maybe (tcdName decl)
   = case thing of -- See Note [Declarations for wired-in things]
-      ATyCon tc -> return tc
+      ATyCon tc -> return (tc, wiredInDerivInfo tc decl)
       _ -> pprPanic "tcTyClDecl" (ppr thing)
 
   | otherwise
   = setSrcSpan loc $ tcAddDeclCtxt decl $
     do { traceTc "---- tcTyClDecl ---- {" (ppr decl)
-       ; tc <- tcTyClDecl1 Nothing roles_info decl
+       ; (tc, deriv_infos) <- tcTyClDecl1 Nothing roles_info decl
        ; traceTc "---- tcTyClDecl end ---- }" (ppr tc)
-       ; return tc }
+       ; return (tc, deriv_infos) }
+
+noDerivInfos :: a -> (a, [DerivInfo])
+noDerivInfos a = (a, [])
+
+wiredInDerivInfo :: TyCon -> TyClDecl GhcRn -> [DerivInfo]
+wiredInDerivInfo tycon decl
+  | DataDecl { tcdDataDefn = dataDefn } <- decl
+  , HsDataDefn { dd_derivs = derivs } <- dataDefn
+  = [ DerivInfo { di_rep_tc = tycon
+                , di_clauses = unLoc derivs
+                , di_ctxt = tcMkDeclCtxt decl } ]
+wiredInDerivInfo _ _ = []
 
   -- "type family" declarations
-tcTyClDecl1 :: Maybe Class -> RolesInfo -> TyClDecl GhcRn -> TcM TyCon
+tcTyClDecl1 :: Maybe Class -> RolesInfo -> TyClDecl GhcRn -> TcM (TyCon, [DerivInfo])
 tcTyClDecl1 parent _roles_info (FamDecl { tcdFam = fd })
-  = tcFamDecl1 parent fd
+  = fmap noDerivInfos $
+    tcFamDecl1 parent fd
 
   -- "type" synonym declaration
 tcTyClDecl1 _parent roles_info
             (SynDecl { tcdLName = (dL->L _ tc_name)
                      , tcdRhs   = rhs })
   = ASSERT( isNothing _parent )
+    fmap noDerivInfos $
     bindTyClTyVars tc_name $ \ binders res_kind ->
     tcTySynRhs roles_info tc_name binders res_kind rhs
 
   -- "data/newtype" declaration
 tcTyClDecl1 _parent roles_info
-            (DataDecl { tcdLName = (dL->L _ tc_name)
-                      , tcdDataDefn = defn })
+            decl@(DataDecl { tcdLName = (dL->L _ tc_name)
+                           , tcdDataDefn = defn })
   = ASSERT( isNothing _parent )
     bindTyClTyVars tc_name $ \ tycon_binders res_kind ->
-    tcDataDefn roles_info tc_name tycon_binders res_kind defn
+    tcDataDefn (tcMkDeclCtxt decl) roles_info tc_name
+               tycon_binders res_kind defn
 
 tcTyClDecl1 _parent roles_info
             (ClassDecl { tcdLName = (dL->L _ class_name)
@@ -1567,7 +1592,7 @@ tcTyClDecl1 _parent roles_info
   = ASSERT( isNothing _parent )
     do { clas <- tcClassDecl1 roles_info class_name hs_ctxt
                               meths fundeps sigs ats at_defs
-       ; return (classTyCon clas) }
+       ; return (noDerivInfos (classTyCon clas)) }
 
 tcTyClDecl1 _ _ (XTyClDecl _) = panic "tcTyClDecl1"
 
@@ -2009,17 +2034,20 @@ tcTySynRhs roles_info tc_name binders res_kind hs_ty
              tycon = buildSynTyCon tc_name binders res_kind roles rhs_ty
        ; return tycon }
 
-tcDataDefn :: RolesInfo -> Name
+tcDataDefn :: SDoc
+           -> RolesInfo -> Name
            -> [TyConBinder] -> Kind
-           -> HsDataDefn GhcRn -> TcM TyCon
+           -> HsDataDefn GhcRn -> TcM (TyCon, [DerivInfo])
   -- NB: not used for newtype/data instances (whether associated or not)
-tcDataDefn roles_info
+tcDataDefn err_ctxt
+           roles_info
            tc_name tycon_binders res_kind
            (HsDataDefn { dd_ND = new_or_data, dd_cType = cType
                        , dd_ctxt = ctxt
                        , dd_kindSig = mb_ksig  -- Already in tc's kind
                                                -- via getInitialKinds
-                       , dd_cons = cons })
+                       , dd_cons = cons
+                       , dd_derivs = derivs })
  =  do { gadt_syntax <- dataDeclChecks tc_name new_or_data ctxt cons
 
        ; tcg_env <- getGblEnv
@@ -2057,8 +2085,11 @@ tcDataDefn roles_info
                                   stupid_theta tc_rhs
                                   (VanillaAlgTyCon tc_rep_nm)
                                   gadt_syntax) }
+       ; let deriv_info = DerivInfo { di_rep_tc = tycon
+                                    , di_clauses = unLoc derivs
+                                    , di_ctxt = err_ctxt }
        ; traceTc "tcDataDefn" (ppr tc_name $$ ppr tycon_binders $$ ppr extra_bndrs)
-       ; return tycon }
+       ; return (tycon, [deriv_info]) }
   where
     -- Abstract data types in hsig files can have arbitrary kinds,
     -- because they may be implemented by type synonyms
@@ -2084,7 +2115,7 @@ tcDataDefn roles_info
           DataType -> return (mkDataTyConRhs data_cons)
           NewType  -> ASSERT( not (null data_cons) )
                       mkNewTyConRhs tc_name tycon (head data_cons)
-tcDataDefn _ _ _ _ (XHsDataDefn _) = panic "tcDataDefn"
+tcDataDefn _ _ _ _ (XHsDataDefn _) = panic "tcDataDefn"
 
 
 -------------------------
index 0c0fb64..c61f5d7 100644 (file)
@@ -1,6 +1,37 @@
 
 ==================== Derived instances ====================
 Derived class instances:
+  instance (GHC.Base.Applicative f, GHC.Base.Applicative g,
+            GHC.Base.Semigroup a) =>
+           GHC.Base.Semigroup (T14578.Wat f g a) where
+    (GHC.Base.<>)
+      = GHC.Prim.coerce
+          @(T14578.App (Data.Functor.Compose.Compose f g) a
+            -> T14578.App (Data.Functor.Compose.Compose f g) a
+               -> T14578.App (Data.Functor.Compose.Compose f g) a)
+          @(T14578.Wat f g a -> T14578.Wat f g a -> T14578.Wat f g a)
+          ((GHC.Base.<>)
+             @(T14578.App (Data.Functor.Compose.Compose f g) a)) ::
+          T14578.Wat f g a -> T14578.Wat f g a -> T14578.Wat f g a
+    GHC.Base.sconcat
+      = GHC.Prim.coerce
+          @(GHC.Base.NonEmpty (T14578.App (Data.Functor.Compose.Compose f g) a)
+            -> T14578.App (Data.Functor.Compose.Compose f g) a)
+          @(GHC.Base.NonEmpty (T14578.Wat f g a) -> T14578.Wat f g a)
+          (GHC.Base.sconcat
+             @(T14578.App (Data.Functor.Compose.Compose f g) a)) ::
+          GHC.Base.NonEmpty (T14578.Wat f g a) -> T14578.Wat f g a
+    GHC.Base.stimes
+      = GHC.Prim.coerce
+          @(b
+            -> T14578.App (Data.Functor.Compose.Compose f g) a
+               -> T14578.App (Data.Functor.Compose.Compose f g) a)
+          @(b -> T14578.Wat f g a -> T14578.Wat f g a)
+          (GHC.Base.stimes
+             @(T14578.App (Data.Functor.Compose.Compose f g) a)) ::
+          forall (b :: TYPE GHC.Types.LiftedRep).
+          GHC.Real.Integral b => b -> T14578.Wat f g a -> T14578.Wat f g a
+  
   instance GHC.Base.Functor f =>
            GHC.Base.Functor (T14578.App f) where
     GHC.Base.fmap
@@ -61,37 +92,6 @@ Derived class instances:
                  (b :: TYPE GHC.Types.LiftedRep).
           T14578.App f a -> T14578.App f b -> T14578.App f a
   
-  instance (GHC.Base.Applicative f, GHC.Base.Applicative g,
-            GHC.Base.Semigroup a) =>
-           GHC.Base.Semigroup (T14578.Wat f g a) where
-    (GHC.Base.<>)
-      = GHC.Prim.coerce
-          @(T14578.App (Data.Functor.Compose.Compose f g) a
-            -> T14578.App (Data.Functor.Compose.Compose f g) a
-               -> T14578.App (Data.Functor.Compose.Compose f g) a)
-          @(T14578.Wat f g a -> T14578.Wat f g a -> T14578.Wat f g a)
-          ((GHC.Base.<>)
-             @(T14578.App (Data.Functor.Compose.Compose f g) a)) ::
-          T14578.Wat f g a -> T14578.Wat f g a -> T14578.Wat f g a
-    GHC.Base.sconcat
-      = GHC.Prim.coerce
-          @(GHC.Base.NonEmpty (T14578.App (Data.Functor.Compose.Compose f g) a)
-            -> T14578.App (Data.Functor.Compose.Compose f g) a)
-          @(GHC.Base.NonEmpty (T14578.Wat f g a) -> T14578.Wat f g a)
-          (GHC.Base.sconcat
-             @(T14578.App (Data.Functor.Compose.Compose f g) a)) ::
-          GHC.Base.NonEmpty (T14578.Wat f g a) -> T14578.Wat f g a
-    GHC.Base.stimes
-      = GHC.Prim.coerce
-          @(b
-            -> T14578.App (Data.Functor.Compose.Compose f g) a
-               -> T14578.App (Data.Functor.Compose.Compose f g) a)
-          @(b -> T14578.Wat f g a -> T14578.Wat f g a)
-          (GHC.Base.stimes
-             @(T14578.App (Data.Functor.Compose.Compose f g) a)) ::
-          forall (b :: TYPE GHC.Types.LiftedRep).
-          GHC.Real.Integral b => b -> T14578.Wat f g a -> T14578.Wat f g a
-  
 
 Derived type family instances:
 
index 133ba6f..d32d06b 100644 (file)
@@ -1,22 +1,6 @@
 
 ==================== Derived instances ====================
 Derived class instances:
-  instance forall a (x :: Data.Proxy.Proxy a).
-           GHC.Classes.Eq a =>
-           GHC.Classes.Eq (T14579.Wat x) where
-    (GHC.Classes.==)
-      = GHC.Prim.coerce
-          @(GHC.Maybe.Maybe a -> GHC.Maybe.Maybe a -> GHC.Types.Bool)
-          @(T14579.Wat @a x -> T14579.Wat @a x -> GHC.Types.Bool)
-          ((GHC.Classes.==) @(GHC.Maybe.Maybe a)) ::
-          T14579.Wat @a x -> T14579.Wat @a x -> GHC.Types.Bool
-    (GHC.Classes./=)
-      = GHC.Prim.coerce
-          @(GHC.Maybe.Maybe a -> GHC.Maybe.Maybe a -> GHC.Types.Bool)
-          @(T14579.Wat @a x -> T14579.Wat @a x -> GHC.Types.Bool)
-          ((GHC.Classes./=) @(GHC.Maybe.Maybe a)) ::
-          T14579.Wat @a x -> T14579.Wat @a x -> GHC.Types.Bool
-  
   instance GHC.Classes.Eq a => GHC.Classes.Eq (T14579.Glurp a) where
     (GHC.Classes.==)
       = GHC.Prim.coerce
@@ -33,6 +17,22 @@ Derived class instances:
           ((GHC.Classes./=) @(T14579.Wat @a (Data.Proxy.Proxy @a))) ::
           T14579.Glurp a -> T14579.Glurp a -> GHC.Types.Bool
   
+  instance forall a (x :: Data.Proxy.Proxy a).
+           GHC.Classes.Eq a =>
+           GHC.Classes.Eq (T14579.Wat x) where
+    (GHC.Classes.==)
+      = GHC.Prim.coerce
+          @(GHC.Maybe.Maybe a -> GHC.Maybe.Maybe a -> GHC.Types.Bool)
+          @(T14579.Wat @a x -> T14579.Wat @a x -> GHC.Types.Bool)
+          ((GHC.Classes.==) @(GHC.Maybe.Maybe a)) ::
+          T14579.Wat @a x -> T14579.Wat @a x -> GHC.Types.Bool
+    (GHC.Classes./=)
+      = GHC.Prim.coerce
+          @(GHC.Maybe.Maybe a -> GHC.Maybe.Maybe a -> GHC.Types.Bool)
+          @(T14579.Wat @a x -> T14579.Wat @a x -> GHC.Types.Bool)
+          ((GHC.Classes./=) @(GHC.Maybe.Maybe a)) ::
+          T14579.Wat @a x -> T14579.Wat @a x -> GHC.Types.Bool
+  
 
 Derived type family instances:
 
index 9c008e0..463609b 100644 (file)
@@ -1,13 +1,13 @@
 
 ==================== Derived instances ====================
 Derived class instances:
-  instance GHC.Generics.Generic (GenDerivOutput.List a) where
+  instance GHC.Generics.Generic (GenDerivOutput.Rose a) where
     GHC.Generics.from x
       = GHC.Generics.M1
           (case x of
-             GenDerivOutput.Nil
+             GenDerivOutput.Empty
                -> GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1)
-             GenDerivOutput.Cons g1 g2
+             GenDerivOutput.Rose g1 g2
                -> GHC.Generics.R1
                     (GHC.Generics.M1
                        ((GHC.Generics.:*:)
@@ -16,47 +16,43 @@ Derived class instances:
     GHC.Generics.to (GHC.Generics.M1 x)
       = case x of
           (GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1))
-            -> GenDerivOutput.Nil
+            -> GenDerivOutput.Empty
           (GHC.Generics.R1 (GHC.Generics.M1 ((GHC.Generics.:*:) (GHC.Generics.M1 (GHC.Generics.K1 g1))
                                                                 (GHC.Generics.M1 (GHC.Generics.K1 g2)))))
-            -> GenDerivOutput.Cons g1 g2
+            -> GenDerivOutput.Rose g1 g2
   
-  instance GHC.Generics.Generic1 GenDerivOutput.List where
+  instance GHC.Generics.Generic1 GenDerivOutput.Rose where
     GHC.Generics.from1 x
       = GHC.Generics.M1
           (case x of
-             GenDerivOutput.Nil
+             GenDerivOutput.Empty
                -> GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1)
-             GenDerivOutput.Cons g1 g2
+             GenDerivOutput.Rose g1 g2
                -> GHC.Generics.R1
                     (GHC.Generics.M1
                        ((GHC.Generics.:*:)
                           (GHC.Generics.M1 (GHC.Generics.Par1 g1))
-                          (GHC.Generics.M1 (GHC.Generics.Rec1 g2)))))
+                          (GHC.Generics.M1
+                             ((GHC.Base..)
+                                GHC.Generics.Comp1 (GHC.Base.fmap GHC.Generics.Rec1) g2)))))
     GHC.Generics.to1 (GHC.Generics.M1 x)
       = case x of
           (GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1))
-            -> GenDerivOutput.Nil
+            -> GenDerivOutput.Empty
           (GHC.Generics.R1 (GHC.Generics.M1 ((GHC.Generics.:*:) (GHC.Generics.M1 g1)
                                                                 (GHC.Generics.M1 g2))))
-            -> GenDerivOutput.Cons
-                 (GHC.Generics.unPar1 g1) (GHC.Generics.unRec1 g2)
-  
-  instance GHC.Base.Functor GenDerivOutput.List where
-    GHC.Base.fmap f GenDerivOutput.Nil = GenDerivOutput.Nil
-    GHC.Base.fmap f (GenDerivOutput.Cons a1 a2)
-      = GenDerivOutput.Cons (f a1) (GHC.Base.fmap f a2)
-    (GHC.Base.<$) z GenDerivOutput.Nil = GenDerivOutput.Nil
-    (GHC.Base.<$) z (GenDerivOutput.Cons a1 a2)
-      = GenDerivOutput.Cons ((\ b1 -> z) a1) ((GHC.Base.<$) z a2)
+            -> GenDerivOutput.Rose
+                 (GHC.Generics.unPar1 g1)
+                 ((GHC.Base..)
+                    (GHC.Base.fmap GHC.Generics.unRec1) GHC.Generics.unComp1 g2)
   
-  instance GHC.Generics.Generic (GenDerivOutput.Rose a) where
+  instance GHC.Generics.Generic (GenDerivOutput.List a) where
     GHC.Generics.from x
       = GHC.Generics.M1
           (case x of
-             GenDerivOutput.Empty
+             GenDerivOutput.Nil
                -> GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1)
-             GenDerivOutput.Rose g1 g2
+             GenDerivOutput.Cons g1 g2
                -> GHC.Generics.R1
                     (GHC.Generics.M1
                        ((GHC.Generics.:*:)
@@ -65,165 +61,169 @@ Derived class instances:
     GHC.Generics.to (GHC.Generics.M1 x)
       = case x of
           (GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1))
-            -> GenDerivOutput.Empty
+            -> GenDerivOutput.Nil
           (GHC.Generics.R1 (GHC.Generics.M1 ((GHC.Generics.:*:) (GHC.Generics.M1 (GHC.Generics.K1 g1))
                                                                 (GHC.Generics.M1 (GHC.Generics.K1 g2)))))
-            -> GenDerivOutput.Rose g1 g2
+            -> GenDerivOutput.Cons g1 g2
   
-  instance GHC.Generics.Generic1 GenDerivOutput.Rose where
+  instance GHC.Generics.Generic1 GenDerivOutput.List where
     GHC.Generics.from1 x
       = GHC.Generics.M1
           (case x of
-             GenDerivOutput.Empty
+             GenDerivOutput.Nil
                -> GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1)
-             GenDerivOutput.Rose g1 g2
+             GenDerivOutput.Cons g1 g2
                -> GHC.Generics.R1
                     (GHC.Generics.M1
                        ((GHC.Generics.:*:)
                           (GHC.Generics.M1 (GHC.Generics.Par1 g1))
-                          (GHC.Generics.M1
-                             ((GHC.Base..)
-                                GHC.Generics.Comp1 (GHC.Base.fmap GHC.Generics.Rec1) g2)))))
+                          (GHC.Generics.M1 (GHC.Generics.Rec1 g2)))))
     GHC.Generics.to1 (GHC.Generics.M1 x)
       = case x of
           (GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1))
-            -> GenDerivOutput.Empty
+            -> GenDerivOutput.Nil
           (GHC.Generics.R1 (GHC.Generics.M1 ((GHC.Generics.:*:) (GHC.Generics.M1 g1)
                                                                 (GHC.Generics.M1 g2))))
-            -> GenDerivOutput.Rose
-                 (GHC.Generics.unPar1 g1)
-                 ((GHC.Base..)
-                    (GHC.Base.fmap GHC.Generics.unRec1) GHC.Generics.unComp1 g2)
+            -> GenDerivOutput.Cons
+                 (GHC.Generics.unPar1 g1) (GHC.Generics.unRec1 g2)
+  
+  instance GHC.Base.Functor GenDerivOutput.List where
+    GHC.Base.fmap f GenDerivOutput.Nil = GenDerivOutput.Nil
+    GHC.Base.fmap f (GenDerivOutput.Cons a1 a2)
+      = GenDerivOutput.Cons (f a1) (GHC.Base.fmap f a2)
+    (GHC.Base.<$) z GenDerivOutput.Nil = GenDerivOutput.Nil
+    (GHC.Base.<$) z (GenDerivOutput.Cons a1 a2)
+      = GenDerivOutput.Cons ((\ b1 -> z) a1) ((GHC.Base.<$) z a2)
   
 
 Derived type family instances:
-  type GHC.Generics.Rep (GenDerivOutput.List a) = GHC.Generics.D1
+  type GHC.Generics.Rep (GenDerivOutput.Rose a) = GHC.Generics.D1
                                                     ('GHC.Generics.MetaData
-                                                       "List"
+                                                       "Rose"
                                                        "GenDerivOutput"
                                                        "main"
                                                        'GHC.Types.False)
                                                     (GHC.Generics.C1
                                                        ('GHC.Generics.MetaCons
-                                                          "Nil"
+                                                          "Empty"
                                                           'GHC.Generics.PrefixI
                                                           'GHC.Types.False)
                                                        GHC.Generics.U1
                                                      GHC.Generics.:+: GHC.Generics.C1
                                                                         ('GHC.Generics.MetaCons
-                                                                           "Cons"
+                                                                           "Rose"
                                                                            'GHC.Generics.PrefixI
-                                                                           'GHC.Types.True)
+                                                                           'GHC.Types.False)
                                                                         (GHC.Generics.S1
                                                                            ('GHC.Generics.MetaSel
-                                                                              ('GHC.Maybe.Just
-                                                                                 "element")
+                                                                              'GHC.Maybe.Nothing
                                                                               'GHC.Generics.NoSourceUnpackedness
                                                                               'GHC.Generics.NoSourceStrictness
                                                                               'GHC.Generics.DecidedLazy)
                                                                            (GHC.Generics.Rec0 a)
                                                                          GHC.Generics.:*: GHC.Generics.S1
                                                                                             ('GHC.Generics.MetaSel
-                                                                                               ('GHC.Maybe.Just
-                                                                                                  "rest")
+                                                                                               'GHC.Maybe.Nothing
                                                                                                'GHC.Generics.NoSourceUnpackedness
                                                                                                'GHC.Generics.NoSourceStrictness
                                                                                                'GHC.Generics.DecidedLazy)
                                                                                             (GHC.Generics.Rec0
                                                                                                (GenDerivOutput.List
-                                                                                                  a))))
-  type GHC.Generics.Rep1 GenDerivOutput.List = GHC.Generics.D1
+                                                                                                  (GenDerivOutput.Rose
+                                                                                                     a)))))
+  type GHC.Generics.Rep1 GenDerivOutput.Rose = GHC.Generics.D1
                                                  ('GHC.Generics.MetaData
-                                                    "List" "GenDerivOutput" "main" 'GHC.Types.False)
+                                                    "Rose" "GenDerivOutput" "main" 'GHC.Types.False)
                                                  (GHC.Generics.C1
                                                     ('GHC.Generics.MetaCons
-                                                       "Nil" 'GHC.Generics.PrefixI 'GHC.Types.False)
+                                                       "Empty"
+                                                       'GHC.Generics.PrefixI
+                                                       'GHC.Types.False)
                                                     GHC.Generics.U1
                                                   GHC.Generics.:+: GHC.Generics.C1
                                                                      ('GHC.Generics.MetaCons
-                                                                        "Cons"
+                                                                        "Rose"
                                                                         'GHC.Generics.PrefixI
-                                                                        'GHC.Types.True)
+                                                                        'GHC.Types.False)
                                                                      (GHC.Generics.S1
                                                                         ('GHC.Generics.MetaSel
-                                                                           ('GHC.Maybe.Just
-                                                                              "element")
+                                                                           'GHC.Maybe.Nothing
                                                                            'GHC.Generics.NoSourceUnpackedness
                                                                            'GHC.Generics.NoSourceStrictness
                                                                            'GHC.Generics.DecidedLazy)
                                                                         GHC.Generics.Par1
                                                                       GHC.Generics.:*: GHC.Generics.S1
                                                                                          ('GHC.Generics.MetaSel
-                                                                                            ('GHC.Maybe.Just
-                                                                                               "rest")
+                                                                                            'GHC.Maybe.Nothing
                                                                                             'GHC.Generics.NoSourceUnpackedness
                                                                                             'GHC.Generics.NoSourceStrictness
                                                                                             'GHC.Generics.DecidedLazy)
-                                                                                         (GHC.Generics.Rec1
-                                                                                            GenDerivOutput.List)))
-  type GHC.Generics.Rep (GenDerivOutput.Rose a) = GHC.Generics.D1
+                                                                                         (GenDerivOutput.List
+                                                                                          GHC.Generics.:.: GHC.Generics.Rec1
+                                                                                                             GenDerivOutput.Rose)))
+  type GHC.Generics.Rep (GenDerivOutput.List a) = GHC.Generics.D1
                                                     ('GHC.Generics.MetaData
-                                                       "Rose"
+                                                       "List"
                                                        "GenDerivOutput"
                                                        "main"
                                                        'GHC.Types.False)
                                                     (GHC.Generics.C1
                                                        ('GHC.Generics.MetaCons
-                                                          "Empty"
+                                                          "Nil"
                                                           'GHC.Generics.PrefixI
                                                           'GHC.Types.False)
                                                        GHC.Generics.U1
                                                      GHC.Generics.:+: GHC.Generics.C1
                                                                         ('GHC.Generics.MetaCons
-                                                                           "Rose"
+                                                                           "Cons"
                                                                            'GHC.Generics.PrefixI
-                                                                           'GHC.Types.False)
+                                                                           'GHC.Types.True)
                                                                         (GHC.Generics.S1
                                                                            ('GHC.Generics.MetaSel
-                                                                              'GHC.Maybe.Nothing
+                                                                              ('GHC.Maybe.Just
+                                                                                 "element")
                                                                               'GHC.Generics.NoSourceUnpackedness
                                                                               'GHC.Generics.NoSourceStrictness
                                                                               'GHC.Generics.DecidedLazy)
                                                                            (GHC.Generics.Rec0 a)
                                                                          GHC.Generics.:*: GHC.Generics.S1
                                                                                             ('GHC.Generics.MetaSel
-                                                                                               'GHC.Maybe.Nothing
+                                                                                               ('GHC.Maybe.Just
+                                                                                                  "rest")
                                                                                                'GHC.Generics.NoSourceUnpackedness
                                                                                                'GHC.Generics.NoSourceStrictness
                                                                                                'GHC.Generics.DecidedLazy)
                                                                                             (GHC.Generics.Rec0
                                                                                                (GenDerivOutput.List
-                                                                                                  (GenDerivOutput.Rose
-                                                                                                     a)))))
-  type GHC.Generics.Rep1 GenDerivOutput.Rose = GHC.Generics.D1
+                                                                                                  a))))
+  type GHC.Generics.Rep1 GenDerivOutput.List = GHC.Generics.D1
                                                  ('GHC.Generics.MetaData
-                                                    "Rose" "GenDerivOutput" "main" 'GHC.Types.False)
+                                                    "List" "GenDerivOutput" "main" 'GHC.Types.False)
                                                  (GHC.Generics.C1
                                                     ('GHC.Generics.MetaCons
-                                                       "Empty"
-                                                       'GHC.Generics.PrefixI
-                                                       'GHC.Types.False)
+                                                       "Nil" 'GHC.Generics.PrefixI 'GHC.Types.False)
                                                     GHC.Generics.U1
                                                   GHC.Generics.:+: GHC.Generics.C1
                                                                      ('GHC.Generics.MetaCons
-                                                                        "Rose"
+                                                                        "Cons"
                                                                         'GHC.Generics.PrefixI
-                                                                        'GHC.Types.False)
+                                                                        'GHC.Types.True)
                                                                      (GHC.Generics.S1
                                                                         ('GHC.Generics.MetaSel
-                                                                           'GHC.Maybe.Nothing
+                                                                           ('GHC.Maybe.Just
+                                                                              "element")
                                                                            'GHC.Generics.NoSourceUnpackedness
                                                                            'GHC.Generics.NoSourceStrictness
                                                                            'GHC.Generics.DecidedLazy)
                                                                         GHC.Generics.Par1
                                                                       GHC.Generics.:*: GHC.Generics.S1
                                                                                          ('GHC.Generics.MetaSel
-                                                                                            'GHC.Maybe.Nothing
+                                                                                            ('GHC.Maybe.Just
+                                                                                               "rest")
                                                                                             'GHC.Generics.NoSourceUnpackedness
                                                                                             'GHC.Generics.NoSourceStrictness
                                                                                             'GHC.Generics.DecidedLazy)
-                                                                                         (GenDerivOutput.List
-                                                                                          GHC.Generics.:.: GHC.Generics.Rec1
-                                                                                                             GenDerivOutput.Rose)))
+                                                                                         (GHC.Generics.Rec1
+                                                                                            GenDerivOutput.List)))
 
 
index 139d7ed..e82a61e 100644 (file)
@@ -83,31 +83,13 @@ Derived class instances:
             -> CanDoRep1_1.D1b
                  (GHC.Generics.unPar1 g1) (GHC.Generics.unRec1 g2)
   
-  instance GHC.Generics.Generic (CanDoRep1_1.Da a) where
-    GHC.Generics.from x
-      = GHC.Generics.M1
-          (case x of
-             CanDoRep1_1.D0 -> GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1)
-             CanDoRep1_1.D1 g1 g2
-               -> GHC.Generics.R1
-                    (GHC.Generics.M1
-                       ((GHC.Generics.:*:)
-                          (GHC.Generics.M1 (GHC.Generics.K1 g1))
-                          (GHC.Generics.M1 (GHC.Generics.K1 g2)))))
-    GHC.Generics.to (GHC.Generics.M1 x)
-      = case x of
-          (GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1))
-            -> CanDoRep1_1.D0
-          (GHC.Generics.R1 (GHC.Generics.M1 ((GHC.Generics.:*:) (GHC.Generics.M1 (GHC.Generics.K1 g1))
-                                                                (GHC.Generics.M1 (GHC.Generics.K1 g2)))))
-            -> CanDoRep1_1.D1 g1 g2
-  
-  instance GHC.Generics.Generic1 CanDoRep1_1.Da where
+  instance GHC.Generics.Generic1 CanDoRep1_1.Dc where
     GHC.Generics.from1 x
       = GHC.Generics.M1
           (case x of
-             CanDoRep1_1.D0 -> GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1)
-             CanDoRep1_1.D1 g1 g2
+             CanDoRep1_1.D0c
+               -> GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1)
+             CanDoRep1_1.D1c g1 g2
                -> GHC.Generics.R1
                     (GHC.Generics.M1
                        ((GHC.Generics.:*:)
@@ -116,10 +98,11 @@ Derived class instances:
     GHC.Generics.to1 (GHC.Generics.M1 x)
       = case x of
           (GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1))
-            -> CanDoRep1_1.D0
+            -> CanDoRep1_1.D0c
           (GHC.Generics.R1 (GHC.Generics.M1 ((GHC.Generics.:*:) (GHC.Generics.M1 g1)
                                                                 (GHC.Generics.M1 g2))))
-            -> CanDoRep1_1.D1 (GHC.Generics.unPar1 g1) (GHC.Generics.unRec1 g2)
+            -> CanDoRep1_1.D1c
+                 (GHC.Generics.unPar1 g1) (GHC.Generics.unRec1 g2)
   
   instance GHC.Generics.Generic (CanDoRep1_1.Db a) where
     GHC.Generics.from x
@@ -141,13 +124,31 @@ Derived class instances:
                                                                 (GHC.Generics.M1 (GHC.Generics.K1 g2)))))
             -> CanDoRep1_1.D1b g1 g2
   
-  instance GHC.Generics.Generic1 CanDoRep1_1.Dc where
+  instance GHC.Generics.Generic (CanDoRep1_1.Da a) where
+    GHC.Generics.from x
+      = GHC.Generics.M1
+          (case x of
+             CanDoRep1_1.D0 -> GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1)
+             CanDoRep1_1.D1 g1 g2
+               -> GHC.Generics.R1
+                    (GHC.Generics.M1
+                       ((GHC.Generics.:*:)
+                          (GHC.Generics.M1 (GHC.Generics.K1 g1))
+                          (GHC.Generics.M1 (GHC.Generics.K1 g2)))))
+    GHC.Generics.to (GHC.Generics.M1 x)
+      = case x of
+          (GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1))
+            -> CanDoRep1_1.D0
+          (GHC.Generics.R1 (GHC.Generics.M1 ((GHC.Generics.:*:) (GHC.Generics.M1 (GHC.Generics.K1 g1))
+                                                                (GHC.Generics.M1 (GHC.Generics.K1 g2)))))
+            -> CanDoRep1_1.D1 g1 g2
+  
+  instance GHC.Generics.Generic1 CanDoRep1_1.Da where
     GHC.Generics.from1 x
       = GHC.Generics.M1
           (case x of
-             CanDoRep1_1.D0c
-               -> GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1)
-             CanDoRep1_1.D1c g1 g2
+             CanDoRep1_1.D0 -> GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1)
+             CanDoRep1_1.D1 g1 g2
                -> GHC.Generics.R1
                     (GHC.Generics.M1
                        ((GHC.Generics.:*:)
@@ -156,11 +157,10 @@ Derived class instances:
     GHC.Generics.to1 (GHC.Generics.M1 x)
       = case x of
           (GHC.Generics.L1 (GHC.Generics.M1 GHC.Generics.U1))
-            -> CanDoRep1_1.D0c
+            -> CanDoRep1_1.D0
           (GHC.Generics.R1 (GHC.Generics.M1 ((GHC.Generics.:*:) (GHC.Generics.M1 g1)
                                                                 (GHC.Generics.M1 g2))))
-            -> CanDoRep1_1.D1c
-                 (GHC.Generics.unPar1 g1) (GHC.Generics.unRec1 g2)
+            -> CanDoRep1_1.D1 (GHC.Generics.unPar1 g1) (GHC.Generics.unRec1 g2)
   
 
 Derived type family instances:
@@ -278,50 +278,21 @@ Derived type family instances:
                                                                                        'GHC.Generics.DecidedLazy)
                                                                                     (GHC.Generics.Rec1
                                                                                        CanDoRep1_1.Db)))
-  type GHC.Generics.Rep (CanDoRep1_1.Da a) = GHC.Generics.D1
-                                               ('GHC.Generics.MetaData
-                                                  "Da" "CanDoRep1_1" "main" 'GHC.Types.False)
-                                               (GHC.Generics.C1
-                                                  ('GHC.Generics.MetaCons
-                                                     "D0" 'GHC.Generics.PrefixI 'GHC.Types.False)
-                                                  GHC.Generics.U1
-                                                GHC.Generics.:+: GHC.Generics.C1
-                                                                   ('GHC.Generics.MetaCons
-                                                                      "D1"
-                                                                      'GHC.Generics.PrefixI
-                                                                      'GHC.Types.True)
-                                                                   (GHC.Generics.S1
-                                                                      ('GHC.Generics.MetaSel
-                                                                         ('GHC.Maybe.Just "d11a")
-                                                                         'GHC.Generics.NoSourceUnpackedness
-                                                                         'GHC.Generics.NoSourceStrictness
-                                                                         'GHC.Generics.DecidedLazy)
-                                                                      (GHC.Generics.Rec0 a)
-                                                                    GHC.Generics.:*: GHC.Generics.S1
-                                                                                       ('GHC.Generics.MetaSel
-                                                                                          ('GHC.Maybe.Just
-                                                                                             "d12a")
-                                                                                          'GHC.Generics.NoSourceUnpackedness
-                                                                                          'GHC.Generics.NoSourceStrictness
-                                                                                          'GHC.Generics.DecidedLazy)
-                                                                                       (GHC.Generics.Rec0
-                                                                                          (CanDoRep1_1.Da
-                                                                                             a))))
-  type GHC.Generics.Rep1 CanDoRep1_1.Da = GHC.Generics.D1
+  type GHC.Generics.Rep1 CanDoRep1_1.Dc = GHC.Generics.D1
                                             ('GHC.Generics.MetaData
-                                               "Da" "CanDoRep1_1" "main" 'GHC.Types.False)
+                                               "Dc" "CanDoRep1_1" "main" 'GHC.Types.False)
                                             (GHC.Generics.C1
                                                ('GHC.Generics.MetaCons
-                                                  "D0" 'GHC.Generics.PrefixI 'GHC.Types.False)
+                                                  "D0c" 'GHC.Generics.PrefixI 'GHC.Types.False)
                                                GHC.Generics.U1
                                              GHC.Generics.:+: GHC.Generics.C1
                                                                 ('GHC.Generics.MetaCons
-                                                                   "D1"
+                                                                   "D1c"
                                                                    'GHC.Generics.PrefixI
                                                                    'GHC.Types.True)
                                                                 (GHC.Generics.S1
                                                                    ('GHC.Generics.MetaSel
-                                                                      ('GHC.Maybe.Just "d11a")
+                                                                      ('GHC.Maybe.Just "d11c")
                                                                       'GHC.Generics.NoSourceUnpackedness
                                                                       'GHC.Generics.NoSourceStrictness
                                                                       'GHC.Generics.DecidedLazy)
@@ -329,12 +300,12 @@ Derived type family instances:
                                                                  GHC.Generics.:*: GHC.Generics.S1
                                                                                     ('GHC.Generics.MetaSel
                                                                                        ('GHC.Maybe.Just
-                                                                                          "d12a")
+                                                                                          "d12c")
                                                                                        'GHC.Generics.NoSourceUnpackedness
                                                                                        'GHC.Generics.NoSourceStrictness
                                                                                        'GHC.Generics.DecidedLazy)
                                                                                     (GHC.Generics.Rec1
-                                                                                       CanDoRep1_1.Da)))
+                                                                                       CanDoRep1_1.Dc)))
   type GHC.Generics.Rep (CanDoRep1_1.Db a) = GHC.Generics.D1
                                                ('GHC.Generics.MetaData
                                                   "Db" "CanDoRep1_1" "main" 'GHC.Types.False)
@@ -364,21 +335,50 @@ Derived type family instances:
                                                                                        (GHC.Generics.Rec0
                                                                                           (CanDoRep1_1.Db
                                                                                              a))))
-  type GHC.Generics.Rep1 CanDoRep1_1.Dc = GHC.Generics.D1
+  type GHC.Generics.Rep (CanDoRep1_1.Da a) = GHC.Generics.D1
+                                               ('GHC.Generics.MetaData
+                                                  "Da" "CanDoRep1_1" "main" 'GHC.Types.False)
+                                               (GHC.Generics.C1
+                                                  ('GHC.Generics.MetaCons
+                                                     "D0" 'GHC.Generics.PrefixI 'GHC.Types.False)
+                                                  GHC.Generics.U1
+                                                GHC.Generics.:+: GHC.Generics.C1
+                                                                   ('GHC.Generics.MetaCons
+                                                                      "D1"
+                                                                      'GHC.Generics.PrefixI
+                                                                      'GHC.Types.True)
+                                                                   (GHC.Generics.S1
+                                                                      ('GHC.Generics.MetaSel
+                                                                         ('GHC.Maybe.Just "d11a")
+                                                                         'GHC.Generics.NoSourceUnpackedness
+                                                                         'GHC.Generics.NoSourceStrictness
+                                                                         'GHC.Generics.DecidedLazy)
+                                                                      (GHC.Generics.Rec0 a)
+                                                                    GHC.Generics.:*: GHC.Generics.S1
+                                                                                       ('GHC.Generics.MetaSel
+                                                                                          ('GHC.Maybe.Just
+                                                                                             "d12a")
+                                                                                          'GHC.Generics.NoSourceUnpackedness
+                                                                                          'GHC.Generics.NoSourceStrictness
+                                                                                          'GHC.Generics.DecidedLazy)
+                                                                                       (GHC.Generics.Rec0
+                                                                                          (CanDoRep1_1.Da
+                                                                                             a))))
+  type GHC.Generics.Rep1 CanDoRep1_1.Da = GHC.Generics.D1
                                             ('GHC.Generics.MetaData
-                                               "Dc" "CanDoRep1_1" "main" 'GHC.Types.False)
+                                               "Da" "CanDoRep1_1" "main" 'GHC.Types.False)
                                             (GHC.Generics.C1
                                                ('GHC.Generics.MetaCons
-                                                  "D0c" 'GHC.Generics.PrefixI 'GHC.Types.False)
+                                                  "D0" 'GHC.Generics.PrefixI 'GHC.Types.False)
                                                GHC.Generics.U1
                                              GHC.Generics.:+: GHC.Generics.C1
                                                                 ('GHC.Generics.MetaCons
-                                                                   "D1c"
+                                                                   "D1"
                                                                    'GHC.Generics.PrefixI
                                                                    'GHC.Types.True)
                                                                 (GHC.Generics.S1
                                                                    ('GHC.Generics.MetaSel
-                                                                      ('GHC.Maybe.Just "d11c")
+                                                                      ('GHC.Maybe.Just "d11a")
                                                                       'GHC.Generics.NoSourceUnpackedness
                                                                       'GHC.Generics.NoSourceStrictness
                                                                       'GHC.Generics.DecidedLazy)
@@ -386,11 +386,11 @@ Derived type family instances:
                                                                  GHC.Generics.:*: GHC.Generics.S1
                                                                                     ('GHC.Generics.MetaSel
                                                                                        ('GHC.Maybe.Just
-                                                                                          "d12c")
+                                                                                          "d12a")
                                                                                        'GHC.Generics.NoSourceUnpackedness
                                                                                        'GHC.Generics.NoSourceStrictness
                                                                                        'GHC.Generics.DecidedLazy)
                                                                                     (GHC.Generics.Rec1
-                                                                                       CanDoRep1_1.Dc)))
+                                                                                       CanDoRep1_1.Da)))
 
 
index 0d42f86..f8a4acc 100644 (file)
@@ -1,89 +1,39 @@
 
 ==================== Derived instances ====================
 Derived class instances:
-  instance GHC.Generics.Generic (T10604_deriving.Empty a) where
-    GHC.Generics.from x
-      = GHC.Generics.M1 (case x of { x -> case x of })
-    GHC.Generics.to (GHC.Generics.M1 x) = case x of { x -> case x of }
-  
-  instance GHC.Generics.Generic1
-             @GHC.Types.Bool T10604_deriving.Empty where
-    GHC.Generics.from1 x
-      = GHC.Generics.M1 (case x of { x -> case x of })
-    GHC.Generics.to1 (GHC.Generics.M1 x) = case x of { x -> case x of }
-  
-  instance GHC.Base.Functor (T10604_deriving.Proxy @*) where
-    GHC.Base.fmap _ = GHC.Prim.coerce
-  
-  instance forall k (a :: k).
-           GHC.Generics.Generic (T10604_deriving.Proxy @k a) where
-    GHC.Generics.from x
-      = GHC.Generics.M1
-          (case x of {
-             T10604_deriving.Proxy -> GHC.Generics.M1 GHC.Generics.U1 })
-    GHC.Generics.to (GHC.Generics.M1 x)
-      = case x of {
-          (GHC.Generics.M1 GHC.Generics.U1) -> T10604_deriving.Proxy }
-  
-  instance GHC.Generics.Generic1 @k (T10604_deriving.Proxy @k) where
-    GHC.Generics.from1 x
-      = GHC.Generics.M1
-          (case x of {
-             T10604_deriving.Proxy -> GHC.Generics.M1 GHC.Generics.U1 })
-    GHC.Generics.to1 (GHC.Generics.M1 x)
-      = case x of {
-          (GHC.Generics.M1 GHC.Generics.U1) -> T10604_deriving.Proxy }
-  
-  instance GHC.Generics.Generic (T10604_deriving.Wrap a) where
-    GHC.Generics.from x
-      = GHC.Generics.M1
-          (case x of {
-             T10604_deriving.Wrap g1
-               -> GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1)) })
-    GHC.Generics.to (GHC.Generics.M1 x)
-      = case x of {
-          (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1)))
-            -> T10604_deriving.Wrap g1 }
-  
-  instance GHC.Generics.Generic1 @(* -> *) T10604_deriving.Wrap where
-    GHC.Generics.from1 x
-      = GHC.Generics.M1
-          (case x of {
-             T10604_deriving.Wrap g1
-               -> GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.Rec1 g1)) })
-    GHC.Generics.to1 (GHC.Generics.M1 x)
-      = case x of {
-          (GHC.Generics.M1 (GHC.Generics.M1 g1))
-            -> T10604_deriving.Wrap (GHC.Generics.unRec1 g1) }
-  
-  instance forall k (a :: k -> *).
-           GHC.Generics.Generic (T10604_deriving.Wrap2 @k a) where
+  instance GHC.Generics.Generic (T10604_deriving.Starify a) where
     GHC.Generics.from x
       = GHC.Generics.M1
-          (case x of {
-             T10604_deriving.Wrap2 g1
-               -> GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1)) })
+          (case x of
+             T10604_deriving.Starify1 g1
+               -> GHC.Generics.L1
+                    (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1)))
+             T10604_deriving.Starify2 g1
+               -> GHC.Generics.R1
+                    (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1))))
     GHC.Generics.to (GHC.Generics.M1 x)
-      = case x of {
-          (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1)))
-            -> T10604_deriving.Wrap2 g1 }
+      = case x of
+          (GHC.Generics.L1 (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1))))
+            -> T10604_deriving.Starify1 g1
+          (GHC.Generics.R1 (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1))))
+            -> T10604_deriving.Starify2 g1
   
-  instance GHC.Generics.Generic1
-             @(k -> *) (T10604_deriving.Wrap2 @k) where
+  instance GHC.Generics.Generic1 @* T10604_deriving.Starify where
     GHC.Generics.from1 x
       = GHC.Generics.M1
-          (case x of {
-             T10604_deriving.Wrap2 g1
-               -> GHC.Generics.M1
-                    (GHC.Generics.M1
-                       ((GHC.Base..)
-                          GHC.Generics.Comp1 (GHC.Base.fmap GHC.Generics.Rec1) g1)) })
+          (case x of
+             T10604_deriving.Starify1 g1
+               -> GHC.Generics.L1
+                    (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.Par1 g1)))
+             T10604_deriving.Starify2 g1
+               -> GHC.Generics.R1
+                    (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1))))
     GHC.Generics.to1 (GHC.Generics.M1 x)
-      = case x of {
-          (GHC.Generics.M1 (GHC.Generics.M1 g1))
-            -> T10604_deriving.Wrap2
-                 ((GHC.Base..)
-                    (GHC.Base.fmap GHC.Generics.unRec1) GHC.Generics.unComp1 g1) }
+      = case x of
+          (GHC.Generics.L1 (GHC.Generics.M1 (GHC.Generics.M1 g1)))
+            -> T10604_deriving.Starify1 (GHC.Generics.unPar1 g1)
+          (GHC.Generics.R1 (GHC.Generics.M1 (GHC.Generics.M1 g1)))
+            -> T10604_deriving.Starify2 (GHC.Generics.unK1 g1)
   
   instance forall k (a :: k).
            GHC.Generics.Generic (T10604_deriving.SumOfProducts @{k} a) where
@@ -139,168 +89,172 @@ Derived class instances:
             -> T10604_deriving.Prod2
                  (GHC.Generics.unRec1 g1) (GHC.Generics.unRec1 g2)
   
-  instance GHC.Generics.Generic (T10604_deriving.Starify a) where
+  instance forall k (a :: k -> *).
+           GHC.Generics.Generic (T10604_deriving.Wrap2 @k a) where
     GHC.Generics.from x
       = GHC.Generics.M1
-          (case x of
-             T10604_deriving.Starify1 g1
-               -> GHC.Generics.L1
-                    (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1)))
-             T10604_deriving.Starify2 g1
-               -> GHC.Generics.R1
-                    (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1))))
+          (case x of {
+             T10604_deriving.Wrap2 g1
+               -> GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1)) })
     GHC.Generics.to (GHC.Generics.M1 x)
-      = case x of
-          (GHC.Generics.L1 (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1))))
-            -> T10604_deriving.Starify1 g1
-          (GHC.Generics.R1 (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1))))
-            -> T10604_deriving.Starify2 g1
+      = case x of {
+          (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1)))
+            -> T10604_deriving.Wrap2 g1 }
   
-  instance GHC.Generics.Generic1 @* T10604_deriving.Starify where
+  instance GHC.Generics.Generic1
+             @(k -> *) (T10604_deriving.Wrap2 @k) where
     GHC.Generics.from1 x
       = GHC.Generics.M1
-          (case x of
-             T10604_deriving.Starify1 g1
-               -> GHC.Generics.L1
-                    (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.Par1 g1)))
-             T10604_deriving.Starify2 g1
-               -> GHC.Generics.R1
-                    (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1))))
+          (case x of {
+             T10604_deriving.Wrap2 g1
+               -> GHC.Generics.M1
+                    (GHC.Generics.M1
+                       ((GHC.Base..)
+                          GHC.Generics.Comp1 (GHC.Base.fmap GHC.Generics.Rec1) g1)) })
     GHC.Generics.to1 (GHC.Generics.M1 x)
-      = case x of
-          (GHC.Generics.L1 (GHC.Generics.M1 (GHC.Generics.M1 g1)))
-            -> T10604_deriving.Starify1 (GHC.Generics.unPar1 g1)
-          (GHC.Generics.R1 (GHC.Generics.M1 (GHC.Generics.M1 g1)))
-            -> T10604_deriving.Starify2 (GHC.Generics.unK1 g1)
+      = case x of {
+          (GHC.Generics.M1 (GHC.Generics.M1 g1))
+            -> T10604_deriving.Wrap2
+                 ((GHC.Base..)
+                    (GHC.Base.fmap GHC.Generics.unRec1) GHC.Generics.unComp1 g1) }
+  
+  instance GHC.Generics.Generic (T10604_deriving.Wrap a) where
+    GHC.Generics.from x
+      = GHC.Generics.M1
+          (case x of {
+             T10604_deriving.Wrap g1
+               -> GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1)) })
+    GHC.Generics.to (GHC.Generics.M1 x)
+      = case x of {
+          (GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.K1 g1)))
+            -> T10604_deriving.Wrap g1 }
+  
+  instance GHC.Generics.Generic1 @(* -> *) T10604_deriving.Wrap where
+    GHC.Generics.from1 x
+      = GHC.Generics.M1
+          (case x of {
+             T10604_deriving.Wrap g1
+               -> GHC.Generics.M1 (GHC.Generics.M1 (GHC.Generics.Rec1 g1)) })
+    GHC.Generics.to1 (GHC.Generics.M1 x)
+      = case x of {
+          (GHC.Generics.M1 (GHC.Generics.M1 g1))
+            -> T10604_deriving.Wrap (GHC.Generics.unRec1 g1) }
+  
+  instance GHC.Base.Functor (T10604_deriving.Proxy @*) where
+    GHC.Base.fmap _ = GHC.Prim.coerce
+  
+  instance forall k (a :: k).
+           GHC.Generics.Generic (T10604_deriving.Proxy @k a) where
+    GHC.Generics.from x
+      = GHC.Generics.M1
+          (case x of {
+             T10604_deriving.Proxy -> GHC.Generics.M1 GHC.Generics.U1 })
+    GHC.Generics.to (GHC.Generics.M1 x)
+      = case x of {
+          (GHC.Generics.M1 GHC.Generics.U1) -> T10604_deriving.Proxy }
+  
+  instance GHC.Generics.Generic1 @k (T10604_deriving.Proxy @k) where
+    GHC.Generics.from1 x
+      = GHC.Generics.M1
+          (case x of {
+             T10604_deriving.Proxy -> GHC.Generics.M1 GHC.Generics.U1 })
+    GHC.Generics.to1 (GHC.Generics.M1 x)
+      = case x of {
+          (GHC.Generics.M1 GHC.Generics.U1) -> T10604_deriving.Proxy }
+  
+  instance GHC.Generics.Generic (T10604_deriving.Empty a) where
+    GHC.Generics.from x
+      = GHC.Generics.M1 (case x of { x -> case x of })
+    GHC.Generics.to (GHC.Generics.M1 x) = case x of { x -> case x of }
+  
+  instance GHC.Generics.Generic1
+             @GHC.Types.Bool T10604_deriving.Empty where
+    GHC.Generics.from1 x
+      = GHC.Generics.M1 (case x of { x -> case x of })
+    GHC.Generics.to1 (GHC.Generics.M1 x) = case x of { x -> case x of }
   
 
 Derived type family instances:
-  type GHC.Generics.Rep (T10604_deriving.Empty a) = GHC.Generics.D1
-                                                      @{*}
-                                                      ('GHC.Generics.MetaData
-                                                         "Empty"
-                                                         "T10604_deriving"
-                                                         "main"
-                                                         'GHC.Types.False)
-                                                      (GHC.Generics.V1 @*)
-  type GHC.Generics.Rep1
-         @GHC.Types.Bool T10604_deriving.Empty = GHC.Generics.D1
-                                                   @{GHC.Types.Bool}
-                                                   ('GHC.Generics.MetaData
-                                                      "Empty"
-                                                      "T10604_deriving"
-                                                      "main"
-                                                      'GHC.Types.False)
-                                                   (GHC.Generics.V1 @GHC.Types.Bool)
-  type GHC.Generics.Rep
-         (T10604_deriving.Proxy @k a) = GHC.Generics.D1
-                                          @{*}
-                                          ('GHC.Generics.MetaData
-                                             "Proxy" "T10604_deriving" "main" 'GHC.Types.False)
-                                          (GHC.Generics.C1
-                                             @{*}
-                                             ('GHC.Generics.MetaCons
-                                                "Proxy" 'GHC.Generics.PrefixI 'GHC.Types.False)
-                                             (GHC.Generics.U1 @*))
-  type GHC.Generics.Rep1
-         @k (T10604_deriving.Proxy @k) = GHC.Generics.D1
-                                           @{k}
-                                           ('GHC.Generics.MetaData
-                                              "Proxy" "T10604_deriving" "main" 'GHC.Types.False)
-                                           (GHC.Generics.C1
-                                              @{k}
-                                              ('GHC.Generics.MetaCons
-                                                 "Proxy" 'GHC.Generics.PrefixI 'GHC.Types.False)
-                                              (GHC.Generics.U1 @k))
-  type GHC.Generics.Rep (T10604_deriving.Wrap a) = GHC.Generics.D1
-                                                     @{*}
-                                                     ('GHC.Generics.MetaData
-                                                        "Wrap"
-                                                        "T10604_deriving"
-                                                        "main"
-                                                        'GHC.Types.False)
-                                                     (GHC.Generics.C1
+  type GHC.Generics.Rep (T10604_deriving.Starify a) = GHC.Generics.D1
                                                         @{*}
-                                                        ('GHC.Generics.MetaCons
-                                                           "Wrap"
-                                                           'GHC.Generics.PrefixI
+                                                        ('GHC.Generics.MetaData
+                                                           "Starify"
+                                                           "T10604_deriving"
+                                                           "main"
                                                            'GHC.Types.False)
-                                                        (GHC.Generics.S1
-                                                           @{*}
-                                                           ('GHC.Generics.MetaSel
-                                                              ('GHC.Maybe.Nothing @GHC.Types.Symbol)
-                                                              'GHC.Generics.NoSourceUnpackedness
-                                                              'GHC.Generics.NoSourceStrictness
-                                                              'GHC.Generics.DecidedLazy)
-                                                           (GHC.Generics.Rec0
+                                                        ((GHC.Generics.:+:)
+                                                           @*
+                                                           (GHC.Generics.C1
                                                               @{*}
-                                                              (T10604_deriving.Proxy @(* -> *) a))))
-  type GHC.Generics.Rep1
-         @(* -> *) T10604_deriving.Wrap = GHC.Generics.D1
-                                            @{* -> *}
-                                            ('GHC.Generics.MetaData
-                                               "Wrap" "T10604_deriving" "main" 'GHC.Types.False)
-                                            (GHC.Generics.C1
-                                               @{* -> *}
-                                               ('GHC.Generics.MetaCons
-                                                  "Wrap" 'GHC.Generics.PrefixI 'GHC.Types.False)
-                                               (GHC.Generics.S1
-                                                  @{* -> *}
-                                                  ('GHC.Generics.MetaSel
-                                                     ('GHC.Maybe.Nothing @GHC.Types.Symbol)
-                                                     'GHC.Generics.NoSourceUnpackedness
-                                                     'GHC.Generics.NoSourceStrictness
-                                                     'GHC.Generics.DecidedLazy)
-                                                  (GHC.Generics.Rec1
-                                                     @(* -> *) (T10604_deriving.Proxy @(* -> *)))))
-  type GHC.Generics.Rep
-         (T10604_deriving.Wrap2 @k a) = GHC.Generics.D1
-                                          @{*}
-                                          ('GHC.Generics.MetaData
-                                             "Wrap2" "T10604_deriving" "main" 'GHC.Types.False)
-                                          (GHC.Generics.C1
-                                             @{*}
-                                             ('GHC.Generics.MetaCons
-                                                "Wrap2" 'GHC.Generics.PrefixI 'GHC.Types.False)
-                                             (GHC.Generics.S1
-                                                @{*}
-                                                ('GHC.Generics.MetaSel
-                                                   ('GHC.Maybe.Nothing @GHC.Types.Symbol)
-                                                   'GHC.Generics.NoSourceUnpackedness
-                                                   'GHC.Generics.NoSourceStrictness
-                                                   'GHC.Generics.DecidedLazy)
-                                                (GHC.Generics.Rec0
-                                                   @{*}
-                                                   (T10604_deriving.Proxy
-                                                      @* (T10604_deriving.Proxy @(k -> *) a)))))
-  type GHC.Generics.Rep1
-         @(k -> *) (T10604_deriving.Wrap2 @k) = GHC.Generics.D1
-                                                  @{k -> *}
-                                                  ('GHC.Generics.MetaData
-                                                     "Wrap2"
-                                                     "T10604_deriving"
-                                                     "main"
-                                                     'GHC.Types.False)
-                                                  (GHC.Generics.C1
-                                                     @{k -> *}
-                                                     ('GHC.Generics.MetaCons
-                                                        "Wrap2"
-                                                        'GHC.Generics.PrefixI
-                                                        'GHC.Types.False)
-                                                     (GHC.Generics.S1
-                                                        @{k -> *}
-                                                        ('GHC.Generics.MetaSel
-                                                           ('GHC.Maybe.Nothing @GHC.Types.Symbol)
-                                                           'GHC.Generics.NoSourceUnpackedness
-                                                           'GHC.Generics.NoSourceStrictness
-                                                           'GHC.Generics.DecidedLazy)
-                                                        ((GHC.Generics.:.:)
+                                                              ('GHC.Generics.MetaCons
+                                                                 "Starify1"
+                                                                 'GHC.Generics.PrefixI
+                                                                 'GHC.Types.False)
+                                                              (GHC.Generics.S1
+                                                                 @{*}
+                                                                 ('GHC.Generics.MetaSel
+                                                                    ('GHC.Maybe.Nothing
+                                                                       @GHC.Types.Symbol)
+                                                                    'GHC.Generics.NoSourceUnpackedness
+                                                                    'GHC.Generics.NoSourceStrictness
+                                                                    'GHC.Generics.DecidedLazy)
+                                                                 (GHC.Generics.Rec0 @{*} a)))
+                                                           (GHC.Generics.C1
+                                                              @{*}
+                                                              ('GHC.Generics.MetaCons
+                                                                 "Starify2"
+                                                                 'GHC.Generics.PrefixI
+                                                                 'GHC.Types.False)
+                                                              (GHC.Generics.S1
+                                                                 @{*}
+                                                                 ('GHC.Generics.MetaSel
+                                                                    ('GHC.Maybe.Nothing
+                                                                       @GHC.Types.Symbol)
+                                                                    'GHC.Generics.NoSourceUnpackedness
+                                                                    'GHC.Generics.NoSourceStrictness
+                                                                    'GHC.Generics.DecidedLazy)
+                                                                 (GHC.Generics.Rec0
+                                                                    @{*} GHC.Types.Int))))
+  type GHC.Generics.Rep1 @* T10604_deriving.Starify = GHC.Generics.D1
+                                                        @{*}
+                                                        ('GHC.Generics.MetaData
+                                                           "Starify"
+                                                           "T10604_deriving"
+                                                           "main"
+                                                           'GHC.Types.False)
+                                                        ((GHC.Generics.:+:)
                                                            @*
-                                                           @(k -> *)
-                                                           (T10604_deriving.Proxy @*)
-                                                           (GHC.Generics.Rec1
-                                                              @(k -> *)
-                                                              (T10604_deriving.Proxy @(k -> *))))))
+                                                           (GHC.Generics.C1
+                                                              @{*}
+                                                              ('GHC.Generics.MetaCons
+                                                                 "Starify1"
+                                                                 'GHC.Generics.PrefixI
+                                                                 'GHC.Types.False)
+                                                              (GHC.Generics.S1
+                                                                 @{*}
+                                                                 ('GHC.Generics.MetaSel
+                                                                    ('GHC.Maybe.Nothing
+                                                                       @GHC.Types.Symbol)
+                                                                    'GHC.Generics.NoSourceUnpackedness
+                                                                    'GHC.Generics.NoSourceStrictness
+                                                                    'GHC.Generics.DecidedLazy)
+                                                                 GHC.Generics.Par1))
+                                                           (GHC.Generics.C1
+                                                              @{*}
+                                                              ('GHC.Generics.MetaCons
+                                                                 "Starify2"
+                                                                 'GHC.Generics.PrefixI
+                                                                 'GHC.Types.False)
+                                                              (GHC.Generics.S1
+                                                                 @{*}
+                                                                 ('GHC.Generics.MetaSel
+                                                                    ('GHC.Maybe.Nothing
+                                                                       @GHC.Types.Symbol)
+                                                                    'GHC.Generics.NoSourceUnpackedness
+                                                                    'GHC.Generics.NoSourceStrictness
+                                                                    'GHC.Generics.DecidedLazy)
+                                                                 (GHC.Generics.Rec0
+                                                                    @{*} GHC.Types.Int))))
   type GHC.Generics.Rep
          (T10604_deriving.SumOfProducts @{k} a) = GHC.Generics.D1
                                                     @{*}
@@ -439,86 +393,132 @@ Derived type family instances:
                                                                  (GHC.Generics.Rec1
                                                                     @k
                                                                     (T10604_deriving.Proxy @k))))))
-  type GHC.Generics.Rep (T10604_deriving.Starify a) = GHC.Generics.D1
-                                                        @{*}
-                                                        ('GHC.Generics.MetaData
-                                                           "Starify"
-                                                           "T10604_deriving"
-                                                           "main"
-                                                           'GHC.Types.False)
-                                                        ((GHC.Generics.:+:)
+  type GHC.Generics.Rep
+         (T10604_deriving.Wrap2 @k a) = GHC.Generics.D1
+                                          @{*}
+                                          ('GHC.Generics.MetaData
+                                             "Wrap2" "T10604_deriving" "main" 'GHC.Types.False)
+                                          (GHC.Generics.C1
+                                             @{*}
+                                             ('GHC.Generics.MetaCons
+                                                "Wrap2" 'GHC.Generics.PrefixI 'GHC.Types.False)
+                                             (GHC.Generics.S1
+                                                @{*}
+                                                ('GHC.Generics.MetaSel
+                                                   ('GHC.Maybe.Nothing @GHC.Types.Symbol)
+                                                   'GHC.Generics.NoSourceUnpackedness
+                                                   'GHC.Generics.NoSourceStrictness
+                                                   'GHC.Generics.DecidedLazy)
+                                                (GHC.Generics.Rec0
+                                                   @{*}
+                                                   (T10604_deriving.Proxy
+                                                      @* (T10604_deriving.Proxy @(k -> *) a)))))
+  type GHC.Generics.Rep1
+         @(k -> *) (T10604_deriving.Wrap2 @k) = GHC.Generics.D1
+                                                  @{k -> *}
+                                                  ('GHC.Generics.MetaData
+                                                     "Wrap2"
+                                                     "T10604_deriving"
+                                                     "main"
+                                                     'GHC.Types.False)
+                                                  (GHC.Generics.C1
+                                                     @{k -> *}
+                                                     ('GHC.Generics.MetaCons
+                                                        "Wrap2"
+                                                        'GHC.Generics.PrefixI
+                                                        'GHC.Types.False)
+                                                     (GHC.Generics.S1
+                                                        @{k -> *}
+                                                        ('GHC.Generics.MetaSel
+                                                           ('GHC.Maybe.Nothing @GHC.Types.Symbol)
+                                                           'GHC.Generics.NoSourceUnpackedness
+                                                           'GHC.Generics.NoSourceStrictness
+                                                           'GHC.Generics.DecidedLazy)
+                                                        ((GHC.Generics.:.:)
                                                            @*
-                                                           (GHC.Generics.C1
-                                                              @{*}
-                                                              ('GHC.Generics.MetaCons
-                                                                 "Starify1"
-                                                                 'GHC.Generics.PrefixI
-                                                                 'GHC.Types.False)
-                                                              (GHC.Generics.S1
-                                                                 @{*}
-                                                                 ('GHC.Generics.MetaSel
-                                                                    ('GHC.Maybe.Nothing
-                                                                       @GHC.Types.Symbol)
-                                                                    'GHC.Generics.NoSourceUnpackedness
-                                                                    'GHC.Generics.NoSourceStrictness
-                                                                    'GHC.Generics.DecidedLazy)
-                                                                 (GHC.Generics.Rec0 @{*} a)))
-                                                           (GHC.Generics.C1
-                                                              @{*}
-                                                              ('GHC.Generics.MetaCons
-                                                                 "Starify2"
-                                                                 'GHC.Generics.PrefixI
-                                                                 'GHC.Types.False)
-                                                              (GHC.Generics.S1
-                                                                 @{*}
-                                                                 ('GHC.Generics.MetaSel
-                                                                    ('GHC.Maybe.Nothing
-                                                                       @GHC.Types.Symbol)
-                                                                    'GHC.Generics.NoSourceUnpackedness
-                                                                    'GHC.Generics.NoSourceStrictness
-                                                                    'GHC.Generics.DecidedLazy)
-                                                                 (GHC.Generics.Rec0
-                                                                    @{*} GHC.Types.Int))))
-  type GHC.Generics.Rep1 @* T10604_deriving.Starify = GHC.Generics.D1
+                                                           @(k -> *)
+                                                           (T10604_deriving.Proxy @*)
+                                                           (GHC.Generics.Rec1
+                                                              @(k -> *)
+                                                              (T10604_deriving.Proxy @(k -> *))))))
+  type GHC.Generics.Rep (T10604_deriving.Wrap a) = GHC.Generics.D1
+                                                     @{*}
+                                                     ('GHC.Generics.MetaData
+                                                        "Wrap"
+                                                        "T10604_deriving"
+                                                        "main"
+                                                        'GHC.Types.False)
+                                                     (GHC.Generics.C1
                                                         @{*}
-                                                        ('GHC.Generics.MetaData
-                                                           "Starify"
-                                                           "T10604_deriving"
-                                                           "main"
+                                                        ('GHC.Generics.MetaCons
+                                                           "Wrap"
+                                                           'GHC.Generics.PrefixI
                                                            'GHC.Types.False)
-                                                        ((GHC.Generics.:+:)
-                                                           @*
-                                                           (GHC.Generics.C1
-                                                              @{*}
-                                                              ('GHC.Generics.MetaCons
-                                                                 "Starify1"
-                                                                 'GHC.Generics.PrefixI
-                                                                 'GHC.Types.False)
-                                                              (GHC.Generics.S1
-                                                                 @{*}
-                                                                 ('GHC.Generics.MetaSel
-                                                                    ('GHC.Maybe.Nothing
-                                                                       @GHC.Types.Symbol)
-                                                                    'GHC.Generics.NoSourceUnpackedness
-                                                                    'GHC.Generics.NoSourceStrictness
-                                                                    'GHC.Generics.DecidedLazy)
-                                                                 GHC.Generics.Par1))
-                                                           (GHC.Generics.C1
+                                                        (GHC.Generics.S1
+                                                           @{*}
+                                                           ('GHC.Generics.MetaSel
+                                                              ('GHC.Maybe.Nothing @GHC.Types.Symbol)
+                                                              'GHC.Generics.NoSourceUnpackedness
+                                                              'GHC.Generics.NoSourceStrictness
+                                                              'GHC.Generics.DecidedLazy)
+                                                           (GHC.Generics.Rec0
                                                               @{*}
-                                                              ('GHC.Generics.MetaCons
-                                                                 "Starify2"
-                                                                 'GHC.Generics.PrefixI
-                                                                 'GHC.Types.False)
-                                                              (GHC.Generics.S1
-                                                                 @{*}
-                                                                 ('GHC.Generics.MetaSel
-                                                                    ('GHC.Maybe.Nothing
-                                                                       @GHC.Types.Symbol)
-                                                                    'GHC.Generics.NoSourceUnpackedness
-                                                                    'GHC.Generics.NoSourceStrictness
-                                                                    'GHC.Generics.DecidedLazy)
-                                                                 (GHC.Generics.Rec0
-                                                                    @{*} GHC.Types.Int))))
+                                                              (T10604_deriving.Proxy @(* -> *) a))))
+  type GHC.Generics.Rep1
+         @(* -> *) T10604_deriving.Wrap = GHC.Generics.D1
+                                            @{* -> *}
+                                            ('GHC.Generics.MetaData
+                                               "Wrap" "T10604_deriving" "main" 'GHC.Types.False)
+                                            (GHC.Generics.C1
+                                               @{* -> *}
+                                               ('GHC.Generics.MetaCons
+                                                  "Wrap" 'GHC.Generics.PrefixI 'GHC.Types.False)
+                                               (GHC.Generics.S1
+                                                  @{* -> *}
+                                                  ('GHC.Generics.MetaSel
+                                                     ('GHC.Maybe.Nothing @GHC.Types.Symbol)
+                                                     'GHC.Generics.NoSourceUnpackedness
+                                                     'GHC.Generics.NoSourceStrictness
+                                                     'GHC.Generics.DecidedLazy)
+                                                  (GHC.Generics.Rec1
+                                                     @(* -> *) (T10604_deriving.Proxy @(* -> *)))))
+  type GHC.Generics.Rep
+         (T10604_deriving.Proxy @k a) = GHC.Generics.D1
+                                          @{*}
+                                          ('GHC.Generics.MetaData
+                                             "Proxy" "T10604_deriving" "main" 'GHC.Types.False)
+                                          (GHC.Generics.C1
+                                             @{*}
+                                             ('GHC.Generics.MetaCons
+                                                "Proxy" 'GHC.Generics.PrefixI 'GHC.Types.False)
+                                             (GHC.Generics.U1 @*))
+  type GHC.Generics.Rep1
+         @k (T10604_deriving.Proxy @k) = GHC.Generics.D1
+                                           @{k}
+                                           ('GHC.Generics.MetaData
+                                              "Proxy" "T10604_deriving" "main" 'GHC.Types.False)
+                                           (GHC.Generics.C1
+                                              @{k}
+                                              ('GHC.Generics.MetaCons
+                                                 "Proxy" 'GHC.Generics.PrefixI 'GHC.Types.False)
+                                              (GHC.Generics.U1 @k))
+  type GHC.Generics.Rep (T10604_deriving.Empty a) = GHC.Generics.D1
+                                                      @{*}
+                                                      ('GHC.Generics.MetaData
+                                                         "Empty"
+                                                         "T10604_deriving"
+                                                         "main"
+                                                         'GHC.Types.False)
+                                                      (GHC.Generics.V1 @*)
+  type GHC.Generics.Rep1
+         @GHC.Types.Bool T10604_deriving.Empty = GHC.Generics.D1
+                                                   @{GHC.Types.Bool}
+                                                   ('GHC.Generics.MetaData
+                                                      "Empty"
+                                                      "T10604_deriving"
+                                                      "main"
+                                                      'GHC.Types.False)
+                                                   (GHC.Generics.V1 @GHC.Types.Bool)