diff --git a/README.md b/README.md index 2619139b..4a2f6820 100644 --- a/README.md +++ b/README.md @@ -634,7 +634,6 @@ instance POrd Bool where type Compare 'True 'True = 'EQ instance SOrd Bool where - sCompare :: forall (x :: a) (y :: a). Sing x -> Sing y -> Sing (Compare x y) sCompare SFalse SFalse = SEQ sCompare SFalse STrue = SLT sCompare STrue SFalse = SGT diff --git a/singletons-base/tests/SingletonsBaseTestSuite.hs b/singletons-base/tests/SingletonsBaseTestSuite.hs index 6560331c..de0e95f2 100644 --- a/singletons-base/tests/SingletonsBaseTestSuite.hs +++ b/singletons-base/tests/SingletonsBaseTestSuite.hs @@ -152,6 +152,7 @@ tests = , compileAndDumpStdTest "T563" , compileAndDumpStdTest "T567" , compileAndDumpStdTest "T571" + , compileAndDumpStdTest "T581" , compileAndDumpStdTest "T585" , compileAndDumpStdTest "TypeAbstractions" ], diff --git a/singletons-base/tests/compile-and-dump/GradingClient/Database.golden b/singletons-base/tests/compile-and-dump/GradingClient/Database.golden index e2e0098d..adedd4fb 100644 --- a/singletons-base/tests/compile-and-dump/GradingClient/Database.golden +++ b/singletons-base/tests/compile-and-dump/GradingClient/Database.golden @@ -92,11 +92,6 @@ GradingClient/Database.hs:(0,0)-(0,0): Splicing declarations toSing (Succ (b :: Demote Nat)) = case toSing b :: SomeSing Nat of SomeSing c -> SomeSing (SSucc c) instance SEq Nat => SEq Nat where - (%==) :: - forall (t1 :: Nat) (t2 :: Nat). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun Nat ((~>) Nat Bool) - -> Type) t1) t2) (%==) SZero SZero = STrue (%==) SZero (SSucc _) = SFalse (%==) (SSucc _) SZero = SFalse @@ -107,11 +102,6 @@ GradingClient/Database.hs:(0,0)-(0,0): Splicing declarations (applySing (singFun2 @(==@#@$) (%==)) sA_0123456789876543210) sB_0123456789876543210 instance SOrd Nat => SOrd Nat where - sCompare :: - forall (t1 :: Nat) (t2 :: Nat). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun Nat ((~>) Nat Ordering) - -> Type) t1) t2) sCompare SZero SZero = applySing (applySing @@ -1626,11 +1616,6 @@ GradingClient/Database.hs:(0,0)-(0,0): Splicing declarations = case toSing b :: SomeSing [Attribute] of SomeSing c -> SomeSing (SSch c) instance (SEq U, SEq Nat) => SEq U where - (%==) :: - forall (t1 :: U) (t2 :: U). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun U ((~>) U Bool) - -> Type) t1) t2) (%==) SBOOL SBOOL = STrue (%==) SBOOL SSTRING = SFalse (%==) SBOOL SNAT = SFalse @@ -1661,14 +1646,6 @@ GradingClient/Database.hs:(0,0)-(0,0): Splicing declarations (applySing (singFun2 @(==@#@$) (%==)) sA_0123456789876543210) sB_0123456789876543210) instance (SShow U, SShow Nat) => SShow U where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: U) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) U ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SBOOL @@ -1728,14 +1705,6 @@ GradingClient/Database.hs:(0,0)-(0,0): Splicing declarations sArg_0123456789876543210))))) sA_0123456789876543210 instance SShow AChar where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: AChar) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) AChar ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SCA @@ -1945,11 +1914,6 @@ GradingClient/Database.hs:(0,0)-(0,0): Splicing declarations (singFun2 @ShowStringSym0 sShowString) (sing :: Sing "CZ")) sA_0123456789876543210 instance SEq AChar where - (%==) :: - forall (t1 :: AChar) (t2 :: AChar). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun AChar ((~>) AChar Bool) - -> Type) t1) t2) (%==) SCA SCA = STrue (%==) SCA SCB = SFalse (%==) SCA SCC = SFalse diff --git a/singletons-base/tests/compile-and-dump/Singletons/BoundedDeriving.golden b/singletons-base/tests/compile-and-dump/Singletons/BoundedDeriving.golden index 08cc4ba2..15caee8c 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/BoundedDeriving.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/BoundedDeriving.golden @@ -115,31 +115,31 @@ Singletons/BoundedDeriving.hs:(0,0)-(0,0): Splicing declarations instance PBounded Foo2 where type MinBound = MinBound_0123456789876543210Sym0 type MaxBound = MaxBound_0123456789876543210Sym0 - type MinBound_0123456789876543210 :: Foo3 a + type MinBound_0123456789876543210 :: forall a. Foo3 a type family MinBound_0123456789876543210 @a :: Foo3 a where - MinBound_0123456789876543210 = Apply Foo3Sym0 MinBoundSym0 - type MinBound_0123456789876543210Sym0 :: Foo3 a + MinBound_0123456789876543210 @a = Apply Foo3Sym0 MinBoundSym0 + type MinBound_0123456789876543210Sym0 :: forall a. Foo3 a type family MinBound_0123456789876543210Sym0 @a :: Foo3 a where MinBound_0123456789876543210Sym0 = MinBound_0123456789876543210 - type MaxBound_0123456789876543210 :: Foo3 a + type MaxBound_0123456789876543210 :: forall a. Foo3 a type family MaxBound_0123456789876543210 @a :: Foo3 a where - MaxBound_0123456789876543210 = Apply Foo3Sym0 MaxBoundSym0 - type MaxBound_0123456789876543210Sym0 :: Foo3 a + MaxBound_0123456789876543210 @a = Apply Foo3Sym0 MaxBoundSym0 + type MaxBound_0123456789876543210Sym0 :: forall a. Foo3 a type family MaxBound_0123456789876543210Sym0 @a :: Foo3 a where MaxBound_0123456789876543210Sym0 = MaxBound_0123456789876543210 instance PBounded (Foo3 a) where type MinBound = MinBound_0123456789876543210Sym0 type MaxBound = MaxBound_0123456789876543210Sym0 - type MinBound_0123456789876543210 :: Foo4 a b + type MinBound_0123456789876543210 :: forall a b. Foo4 a b type family MinBound_0123456789876543210 @a @b :: Foo4 a b where - MinBound_0123456789876543210 = Foo41Sym0 - type MinBound_0123456789876543210Sym0 :: Foo4 a b + MinBound_0123456789876543210 @a @b = Foo41Sym0 + type MinBound_0123456789876543210Sym0 :: forall a b. Foo4 a b type family MinBound_0123456789876543210Sym0 @a @b :: Foo4 a b where MinBound_0123456789876543210Sym0 = MinBound_0123456789876543210 - type MaxBound_0123456789876543210 :: Foo4 a b + type MaxBound_0123456789876543210 :: forall a b. Foo4 a b type family MaxBound_0123456789876543210 @a @b :: Foo4 a b where - MaxBound_0123456789876543210 = Foo42Sym0 - type MaxBound_0123456789876543210Sym0 :: Foo4 a b + MaxBound_0123456789876543210 @a @b = Foo42Sym0 + type MaxBound_0123456789876543210Sym0 :: forall a b. Foo4 a b type family MaxBound_0123456789876543210Sym0 @a @b :: Foo4 a b where MaxBound_0123456789876543210Sym0 = MaxBound_0123456789876543210 instance PBounded (Foo4 a b) where @@ -220,28 +220,18 @@ Singletons/BoundedDeriving.hs:(0,0)-(0,0): Splicing declarations of (,) (SomeSing c) (SomeSing c) -> SomeSing (SPair c c) instance SBounded Foo1 where - sMinBound :: Sing (MinBoundSym0 :: Foo1) - sMaxBound :: Sing (MaxBoundSym0 :: Foo1) sMinBound = SFoo1 sMaxBound = SFoo1 instance SBounded Foo2 where - sMinBound :: Sing (MinBoundSym0 :: Foo2) - sMaxBound :: Sing (MaxBoundSym0 :: Foo2) sMinBound = SA sMaxBound = SE instance SBounded a => SBounded (Foo3 a) where - sMinBound :: Sing (MinBoundSym0 :: Foo3 a) - sMaxBound :: Sing (MaxBoundSym0 :: Foo3 a) sMinBound = applySing (singFun1 @Foo3Sym0 SFoo3) sMinBound sMaxBound = applySing (singFun1 @Foo3Sym0 SFoo3) sMaxBound instance SBounded (Foo4 a b) where - sMinBound :: Sing (MinBoundSym0 :: Foo4 a b) - sMaxBound :: Sing (MaxBoundSym0 :: Foo4 a b) sMinBound = SFoo41 sMaxBound = SFoo42 instance SBounded Bool => SBounded Pair where - sMinBound :: Sing (MinBoundSym0 :: Pair) - sMaxBound :: Sing (MaxBoundSym0 :: Pair) sMinBound = applySing (applySing (singFun2 @PairSym0 SPair) sMinBound) sMinBound diff --git a/singletons-base/tests/compile-and-dump/Singletons/Classes.golden b/singletons-base/tests/compile-and-dump/Singletons/Classes.golden index cd3f1ce5..55ac5b52 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/Classes.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/Classes.golden @@ -159,10 +159,10 @@ Singletons/Classes.hs:(0,0)-(0,0): Splicing declarations type family (<=>@#@$$$) @a (a0123456789876543210 :: a) (a0123456789876543210 :: a) :: Ordering where (<=>@#@$$$) a0123456789876543210 a0123456789876543210 = (<=>) a0123456789876543210 a0123456789876543210 infix 4 <=>@#@$$$ - type TFHelper_0123456789876543210 :: a -> a -> Ordering + type TFHelper_0123456789876543210 :: forall a. a -> a -> Ordering type family TFHelper_0123456789876543210 @a (a :: a) (a :: a) :: Ordering where - TFHelper_0123456789876543210 a_0123456789876543210 a_0123456789876543210 = Apply (Apply MycompareSym0 a_0123456789876543210) a_0123456789876543210 - type TFHelper_0123456789876543210Sym0 :: (~>) a ((~>) a Ordering) + TFHelper_0123456789876543210 @a (a_0123456789876543210 :: a) (a_0123456789876543210 :: a) = Apply (Apply MycompareSym0 a_0123456789876543210) a_0123456789876543210 + type TFHelper_0123456789876543210Sym0 :: forall a. (~>) a ((~>) a Ordering) data TFHelper_0123456789876543210Sym0 :: (~>) a ((~>) a Ordering) where TFHelper_0123456789876543210Sym0KindInference :: SameKind (Apply TFHelper_0123456789876543210Sym0 arg) (TFHelper_0123456789876543210Sym1 arg) => @@ -171,7 +171,8 @@ Singletons/Classes.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings TFHelper_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym0KindInference ()) - type TFHelper_0123456789876543210Sym1 :: a -> (~>) a Ordering + type TFHelper_0123456789876543210Sym1 :: forall a. a + -> (~>) a Ordering data TFHelper_0123456789876543210Sym1 (a0123456789876543210 :: a) :: (~>) a Ordering where TFHelper_0123456789876543210Sym1KindInference :: SameKind (Apply (TFHelper_0123456789876543210Sym1 a0123456789876543210) arg) (TFHelper_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -180,7 +181,8 @@ Singletons/Classes.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (TFHelper_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym1KindInference ()) - type TFHelper_0123456789876543210Sym2 :: a -> a -> Ordering + type TFHelper_0123456789876543210Sym2 :: forall a. a + -> a -> Ordering type family TFHelper_0123456789876543210Sym2 @a (a0123456789876543210 :: a) (a0123456789876543210 :: a) :: Ordering where TFHelper_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = TFHelper_0123456789876543210 a0123456789876543210 a0123456789876543210 class PMyOrd a where @@ -376,31 +378,16 @@ Singletons/Classes.hs:(0,0)-(0,0): Splicing declarations (singFun2 @MycompareSym0 sMycompare) sA_0123456789876543210) sA_0123456789876543210 instance SMyOrd Nat where - sMycompare :: - (forall (t :: Nat) (t :: Nat). - Sing t - -> Sing t - -> Sing (Apply (Apply MycompareSym0 t) t :: Ordering) :: Type) sMycompare SZero SZero = SEQ sMycompare SZero (SSucc _) = SLT sMycompare (SSucc _) SZero = SGT sMycompare (SSucc (sN :: Sing n)) (SSucc (sM :: Sing m)) = applySing (applySing (singFun2 @MycompareSym0 sMycompare) sM) sN instance SMyOrd () where - sMycompare :: - (forall (t :: ()) (t :: ()). - Sing t - -> Sing t - -> Sing (Apply (Apply MycompareSym0 t) t :: Ordering) :: Type) sMycompare _ (sA_0123456789876543210 :: Sing a_0123456789876543210) = applySing (applySing (singFun2 @ConstSym0 sConst) SEQ) sA_0123456789876543210 instance SMyOrd Foo where - sMycompare :: - (forall (t :: Foo) (t :: Foo). - Sing t - -> Sing t - -> Sing (Apply (Apply MycompareSym0 t) t :: Ordering) :: Type) sMycompare (sA_0123456789876543210 :: Sing a_0123456789876543210) (sA_0123456789876543210 :: Sing a_0123456789876543210) @@ -409,11 +396,6 @@ Singletons/Classes.hs:(0,0)-(0,0): Splicing declarations (singFun2 @FooCompareSym0 sFooCompare) sA_0123456789876543210) sA_0123456789876543210 instance SEq Foo2 where - (%==) :: - forall (t1 :: Foo2) (t2 :: Foo2). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun Foo2 ((~>) Foo2 Bool) - -> Type) t1) t2) (%==) SF SF = STrue (%==) SG SG = STrue (%==) SF SG = SFalse @@ -596,11 +578,6 @@ Singletons/Classes.hs:(0,0)-(0,0): Splicing declarations = case toSing b :: SomeSing Nat' of SomeSing c -> SomeSing (SSucc' c) instance SMyOrd Nat' where - sMycompare :: - forall (t :: Nat') (t :: Nat'). Sing t - -> Sing t - -> Sing (Apply (Apply (MycompareSym0 :: TyFun Nat' ((~>) Nat' Ordering) - -> Type) t) t) sMycompare SZero' SZero' = SEQ sMycompare SZero' (SSucc' _) = SLT sMycompare (SSucc' _) SZero' = SGT diff --git a/singletons-base/tests/compile-and-dump/Singletons/Classes2.golden b/singletons-base/tests/compile-and-dump/Singletons/Classes2.golden index 56f640d7..6bf5f3eb 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/Classes2.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/Classes2.golden @@ -74,11 +74,6 @@ Singletons/Classes2.hs:(0,0)-(0,0): Splicing declarations = case toSing b :: SomeSing NatFoo of SomeSing c -> SomeSing (SSuccFoo c) instance SMyOrd NatFoo where - sMycompare :: - forall (t1 :: NatFoo) (t2 :: NatFoo). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (MycompareSym0 :: TyFun NatFoo ((~>) NatFoo Ordering) - -> Type) t1) t2) sMycompare SZeroFoo SZeroFoo = SEQ sMycompare SZeroFoo (SSuccFoo _) = SLT sMycompare (SSuccFoo _) SZeroFoo = SGT diff --git a/singletons-base/tests/compile-and-dump/Singletons/DataValues.golden b/singletons-base/tests/compile-and-dump/Singletons/DataValues.golden index 2c24a1dd..3db747b9 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/DataValues.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/DataValues.golden @@ -51,11 +51,13 @@ Singletons/DataValues.hs:(0,0)-(0,0): Splicing declarations Complex = Apply (Apply PairSym0 (Apply (Apply PairSym0 (Apply JustSym0 ZeroSym0)) ZeroSym0)) FalseSym0 type family Pr where Pr = Apply (Apply PairSym0 (Apply SuccSym0 ZeroSym0)) (Apply (Apply (:@#@$) ZeroSym0) NilSym0) - type ShowsPrec_0123456789876543210 :: GHC.Num.Natural.Natural - -> Pair a b -> Symbol -> Symbol + type ShowsPrec_0123456789876543210 :: forall a + b. GHC.Num.Natural.Natural + -> Pair a b -> Symbol -> Symbol type family ShowsPrec_0123456789876543210 @a @b (a :: GHC.Num.Natural.Natural) (a :: Pair a b) (a :: Symbol) :: Symbol where - ShowsPrec_0123456789876543210 p_0123456789876543210 (Pair arg_0123456789876543210 arg_0123456789876543210) a_0123456789876543210 = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "Pair ")) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210)) (Apply (Apply (.@#@$) ShowSpaceSym0) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))))) a_0123456789876543210 - type ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (Pair a b) ((~>) Symbol Symbol)) + ShowsPrec_0123456789876543210 @a @b (p_0123456789876543210 :: GHC.Num.Natural.Natural) (Pair arg_0123456789876543210 arg_0123456789876543210 :: Pair a b) (a_0123456789876543210 :: Symbol) = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "Pair ")) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210)) (Apply (Apply (.@#@$) ShowSpaceSym0) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))))) a_0123456789876543210 + type ShowsPrec_0123456789876543210Sym0 :: forall a + b. (~>) GHC.Num.Natural.Natural ((~>) (Pair a b) ((~>) Symbol Symbol)) data ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (Pair a b) ((~>) Symbol Symbol)) where ShowsPrec_0123456789876543210Sym0KindInference :: SameKind (Apply ShowsPrec_0123456789876543210Sym0 arg) (ShowsPrec_0123456789876543210Sym1 arg) => @@ -64,8 +66,9 @@ Singletons/DataValues.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings ShowsPrec_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym0KindInference ()) - type ShowsPrec_0123456789876543210Sym1 :: GHC.Num.Natural.Natural - -> (~>) (Pair a b) ((~>) Symbol Symbol) + type ShowsPrec_0123456789876543210Sym1 :: forall a + b. GHC.Num.Natural.Natural + -> (~>) (Pair a b) ((~>) Symbol Symbol) data ShowsPrec_0123456789876543210Sym1 (a0123456789876543210 :: GHC.Num.Natural.Natural) :: (~>) (Pair a b) ((~>) Symbol Symbol) where ShowsPrec_0123456789876543210Sym1KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -74,8 +77,9 @@ Singletons/DataValues.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym1KindInference ()) - type ShowsPrec_0123456789876543210Sym2 :: GHC.Num.Natural.Natural - -> Pair a b -> (~>) Symbol Symbol + type ShowsPrec_0123456789876543210Sym2 :: forall a + b. GHC.Num.Natural.Natural + -> Pair a b -> (~>) Symbol Symbol data ShowsPrec_0123456789876543210Sym2 (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: Pair a b) :: (~>) Symbol Symbol where ShowsPrec_0123456789876543210Sym2KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 arg) => @@ -84,8 +88,9 @@ Singletons/DataValues.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym2KindInference ()) - type ShowsPrec_0123456789876543210Sym3 :: GHC.Num.Natural.Natural - -> Pair a b -> Symbol -> Symbol + type ShowsPrec_0123456789876543210Sym3 :: forall a + b. GHC.Num.Natural.Natural + -> Pair a b -> Symbol -> Symbol type family ShowsPrec_0123456789876543210Sym3 @a @b (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: Pair a b) (a0123456789876543210 :: Symbol) :: Symbol where ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 a0123456789876543210 = ShowsPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210 instance PShow (Pair a b) where @@ -142,14 +147,6 @@ Singletons/DataValues.hs:(0,0)-(0,0): Splicing declarations = case (,) (toSing b :: SomeSing a) (toSing b :: SomeSing b) of (,) (SomeSing c) (SomeSing c) -> SomeSing (SPair c c) instance (SShow a, SShow b) => SShow (Pair a b) where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: Pair a b) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) (Pair a b) ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec (sP_0123456789876543210 :: Sing p_0123456789876543210) (SPair (sArg_0123456789876543210 :: Sing arg_0123456789876543210) diff --git a/singletons-base/tests/compile-and-dump/Singletons/EmptyShowDeriving.golden b/singletons-base/tests/compile-and-dump/Singletons/EmptyShowDeriving.golden index 5e18ef69..a32d845f 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/EmptyShowDeriving.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/EmptyShowDeriving.golden @@ -53,14 +53,6 @@ Singletons/EmptyShowDeriving.hs:(0,0)-(0,0): Splicing declarations fromSing x = case x of {} toSing x = SomeSing (case x of {}) instance SShow Foo where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: Foo) - (t3 :: GHC.Types.Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) Foo ((~>) GHC.Types.Symbol GHC.Types.Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ (sV_0123456789876543210 :: Sing v_0123456789876543210) diff --git a/singletons-base/tests/compile-and-dump/Singletons/EnumDeriving.golden b/singletons-base/tests/compile-and-dump/Singletons/EnumDeriving.golden index 9c9ce3c6..37d486bd 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/EnumDeriving.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/EnumDeriving.golden @@ -96,14 +96,6 @@ Singletons/EnumDeriving.hs:(0,0)-(0,0): Splicing declarations toSing Q1 = SomeSing SQ1 toSing Q2 = SomeSing SQ2 instance SEnum Foo where - sToEnum :: - forall (t :: GHC.Num.Natural.Natural). Sing t - -> Sing (Apply (Data.Singletons.Base.Enum.ToEnumSym0 :: TyFun GHC.Num.Natural.Natural Foo - -> Type) t) - sFromEnum :: - forall (t :: Foo). Sing t - -> Sing (Apply (Data.Singletons.Base.Enum.FromEnumSym0 :: TyFun Foo GHC.Num.Natural.Natural - -> Type) t) sToEnum (sN :: Sing n) = id @(Sing (Case_0123456789876543210 n (Apply (Apply (==@#@$) n) (FromInteger 0)))) @@ -195,14 +187,6 @@ Singletons/EnumDeriving.hs:0:0:: Splicing declarations type ToEnum a = Apply ToEnum_0123456789876543210Sym0 a type FromEnum a = Apply FromEnum_0123456789876543210Sym0 a instance SEnum Quux where - sToEnum :: - forall (t :: GHC.Num.Natural.Natural). Sing t - -> Sing (Apply (Data.Singletons.Base.Enum.ToEnumSym0 :: TyFun GHC.Num.Natural.Natural Quux - -> Type) t) - sFromEnum :: - forall (t :: Quux). Sing t - -> Sing (Apply (Data.Singletons.Base.Enum.FromEnumSym0 :: TyFun Quux GHC.Num.Natural.Natural - -> Type) t) sToEnum (sN :: Sing n) = id @(Sing (Case_0123456789876543210 n (Apply (Apply (==@#@$) n) (FromInteger 0)))) diff --git a/singletons-base/tests/compile-and-dump/Singletons/EqInstances.golden b/singletons-base/tests/compile-and-dump/Singletons/EqInstances.golden index d538d165..35a6eb9f 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/EqInstances.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/EqInstances.golden @@ -31,11 +31,6 @@ Singletons/EqInstances.hs:0:0:: Splicing declarations instance PEq Foo where type (==) a a = Apply (Apply TFHelper_0123456789876543210Sym0 a) a instance SEq Foo => SEq Foo where - (%==) :: - forall (t1 :: Foo) (t2 :: Foo). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun Foo ((~>) Foo Bool) - -> Type) t1) t2) (%==) SFLeaf SFLeaf = STrue (%==) SFLeaf ((:%+:) _ _) = SFalse (%==) ((:%+:) _ _) SFLeaf = SFalse @@ -80,9 +75,4 @@ Singletons/EqInstances.hs:0:0:: Splicing declarations instance PEq Empty where type (==) a a = Apply (Apply TFHelper_0123456789876543210Sym0 a) a instance SEq Empty where - (%==) :: - forall (t1 :: Empty) (t2 :: Empty). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun Empty ((~>) Empty Bool) - -> Type) t1) t2) (%==) _ _ = STrue diff --git a/singletons-base/tests/compile-and-dump/Singletons/FunDeps.golden b/singletons-base/tests/compile-and-dump/Singletons/FunDeps.golden index e6173c3f..1808bd31 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/FunDeps.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/FunDeps.golden @@ -90,12 +90,6 @@ Singletons/FunDeps.hs:(0,0)-(0,0): Splicing declarations sL2r :: (forall (t :: a). Sing t -> Sing (Apply L2rSym0 t :: b) :: Type) instance SFD Bool Natural where - sMeth :: - (forall (t :: Bool). - Sing t -> Sing (Apply MethSym0 t :: Bool) :: Type) - sL2r :: - (forall (t :: Bool). - Sing t -> Sing (Apply L2rSym0 t :: Natural) :: Type) sMeth (sA_0123456789876543210 :: Sing a_0123456789876543210) = applySing (singFun1 @NotSym0 sNot) sA_0123456789876543210 sL2r SFalse = sFromInteger (sing :: Sing 0) diff --git a/singletons-base/tests/compile-and-dump/Singletons/FunctorLikeDeriving.golden b/singletons-base/tests/compile-and-dump/Singletons/FunctorLikeDeriving.golden index 1eed5127..d2ed4d2d 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/FunctorLikeDeriving.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/FunctorLikeDeriving.golden @@ -60,35 +60,38 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations type MkT2Sym1 :: forall x a. Maybe x -> T x a type family MkT2Sym1 @x @a (a0123456789876543210 :: Maybe x) :: T x a where MkT2Sym1 a0123456789876543210 = MkT2 a0123456789876543210 - type family Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where - Lambda_0123456789876543210 _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = n_0123456789876543210 - data Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where + Lambda_0123456789876543210 x _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = n_0123456789876543210 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - type family Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type family Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where - Lambda_0123456789876543210 _f_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = n_0123456789876543210 - data Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where + Lambda_0123456789876543210 x _f_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = n_0123456789876543210 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - type family Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type Fmap_0123456789876543210 :: (~>) a b -> T x a -> T x b + type family Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type Fmap_0123456789876543210 :: forall a b x. (~>) a b + -> T x a -> T x b type family Fmap_0123456789876543210 @a @b @x (a :: (~>) a b) (a :: T x a) :: T x b where - Fmap_0123456789876543210 _f_0123456789876543210 (MkT1 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) = Apply (Apply (Apply (Apply MkT1Sym0 (Apply (Lambda_0123456789876543210Sym0 _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210)) (Apply _f_0123456789876543210 a_0123456789876543210)) (Apply (Apply FmapSym0 _f_0123456789876543210) a_0123456789876543210)) (Apply (Apply FmapSym0 (Apply FmapSym0 _f_0123456789876543210)) a_0123456789876543210) - Fmap_0123456789876543210 _f_0123456789876543210 (MkT2 a_0123456789876543210) = Apply MkT2Sym0 (Apply (Lambda_0123456789876543210Sym0 _f_0123456789876543210 a_0123456789876543210) a_0123456789876543210) - type Fmap_0123456789876543210Sym0 :: (~>) ((~>) a b) ((~>) (T x a) (T x b)) + Fmap_0123456789876543210 @a @b @x (_f_0123456789876543210 :: (~>) a b) (MkT1 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: T x a) = Apply (Apply (Apply (Apply MkT1Sym0 (Apply (Lambda_0123456789876543210Sym0 x _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210)) (Apply _f_0123456789876543210 a_0123456789876543210)) (Apply (Apply FmapSym0 _f_0123456789876543210) a_0123456789876543210)) (Apply (Apply FmapSym0 (Apply FmapSym0 _f_0123456789876543210)) a_0123456789876543210) + Fmap_0123456789876543210 @a @b @x (_f_0123456789876543210 :: (~>) a b) (MkT2 a_0123456789876543210 :: T x a) = Apply MkT2Sym0 (Apply (Lambda_0123456789876543210Sym0 x _f_0123456789876543210 a_0123456789876543210) a_0123456789876543210) + type Fmap_0123456789876543210Sym0 :: forall a + b + x. (~>) ((~>) a b) ((~>) (T x a) (T x b)) data Fmap_0123456789876543210Sym0 :: (~>) ((~>) a b) ((~>) (T x a) (T x b)) where Fmap_0123456789876543210Sym0KindInference :: SameKind (Apply Fmap_0123456789876543210Sym0 arg) (Fmap_0123456789876543210Sym1 arg) => @@ -97,8 +100,8 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Fmap_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Fmap_0123456789876543210Sym0KindInference ()) - type Fmap_0123456789876543210Sym1 :: (~>) a b - -> (~>) (T x a) (T x b) + type Fmap_0123456789876543210Sym1 :: forall a b x. (~>) a b + -> (~>) (T x a) (T x b) data Fmap_0123456789876543210Sym1 (a0123456789876543210 :: (~>) a b) :: (~>) (T x a) (T x b) where Fmap_0123456789876543210Sym1KindInference :: SameKind (Apply (Fmap_0123456789876543210Sym1 a0123456789876543210) arg) (Fmap_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -107,50 +110,54 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Fmap_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Fmap_0123456789876543210Sym1KindInference ()) - type Fmap_0123456789876543210Sym2 :: (~>) a b -> T x a -> T x b + type Fmap_0123456789876543210Sym2 :: forall a b x. (~>) a b + -> T x a -> T x b type family Fmap_0123456789876543210Sym2 @a @b @x (a0123456789876543210 :: (~>) a b) (a0123456789876543210 :: T x a) :: T x b where Fmap_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Fmap_0123456789876543210 a0123456789876543210 a0123456789876543210 - type family Lambda_0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where - Lambda_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = n_0123456789876543210 - data Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where + Lambda_0123456789876543210 x _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = n_0123456789876543210 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - type family Lambda_0123456789876543210Sym1 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type family Lambda_0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where - Lambda_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = _z_0123456789876543210 - data Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210Sym1 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym1 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where + Lambda_0123456789876543210 x _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = _z_0123456789876543210 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - type family Lambda_0123456789876543210Sym1 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type family Lambda_0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where - Lambda_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = n_0123456789876543210 - data Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210Sym1 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym1 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where + Lambda_0123456789876543210 x _z_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = n_0123456789876543210 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - type family Lambda_0123456789876543210Sym1 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type TFHelper_0123456789876543210 :: a -> T x b -> T x a + type family Lambda_0123456789876543210Sym1 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym1 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type TFHelper_0123456789876543210 :: forall a x b. a + -> T x b -> T x a type family TFHelper_0123456789876543210 @a @x @b (a :: a) (a :: T x b) :: T x a where - TFHelper_0123456789876543210 _z_0123456789876543210 (MkT1 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) = Apply (Apply (Apply (Apply MkT1Sym0 (Apply (Lambda_0123456789876543210Sym0 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210)) (Apply (Lambda_0123456789876543210Sym0 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210)) (Apply (Apply (<$@#@$) _z_0123456789876543210) a_0123456789876543210)) (Apply (Apply FmapSym0 (Apply (<$@#@$) _z_0123456789876543210)) a_0123456789876543210) - TFHelper_0123456789876543210 _z_0123456789876543210 (MkT2 a_0123456789876543210) = Apply MkT2Sym0 (Apply (Lambda_0123456789876543210Sym0 _z_0123456789876543210 a_0123456789876543210) a_0123456789876543210) - type TFHelper_0123456789876543210Sym0 :: (~>) a ((~>) (T x b) (T x a)) + TFHelper_0123456789876543210 @a @x @b (_z_0123456789876543210 :: a) (MkT1 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: T x b) = Apply (Apply (Apply (Apply MkT1Sym0 (Apply (Lambda_0123456789876543210Sym0 x _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210)) (Apply (Lambda_0123456789876543210Sym0 x _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210)) (Apply (Apply (<$@#@$) _z_0123456789876543210) a_0123456789876543210)) (Apply (Apply FmapSym0 (Apply (<$@#@$) _z_0123456789876543210)) a_0123456789876543210) + TFHelper_0123456789876543210 @a @x @b (_z_0123456789876543210 :: a) (MkT2 a_0123456789876543210 :: T x b) = Apply MkT2Sym0 (Apply (Lambda_0123456789876543210Sym0 x _z_0123456789876543210 a_0123456789876543210) a_0123456789876543210) + type TFHelper_0123456789876543210Sym0 :: forall a + x + b. (~>) a ((~>) (T x b) (T x a)) data TFHelper_0123456789876543210Sym0 :: (~>) a ((~>) (T x b) (T x a)) where TFHelper_0123456789876543210Sym0KindInference :: SameKind (Apply TFHelper_0123456789876543210Sym0 arg) (TFHelper_0123456789876543210Sym1 arg) => @@ -159,7 +166,8 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings TFHelper_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym0KindInference ()) - type TFHelper_0123456789876543210Sym1 :: a -> (~>) (T x b) (T x a) + type TFHelper_0123456789876543210Sym1 :: forall a x b. a + -> (~>) (T x b) (T x a) data TFHelper_0123456789876543210Sym1 (a0123456789876543210 :: a) :: (~>) (T x b) (T x a) where TFHelper_0123456789876543210Sym1KindInference :: SameKind (Apply (TFHelper_0123456789876543210Sym1 a0123456789876543210) arg) (TFHelper_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -168,41 +176,45 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (TFHelper_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym1KindInference ()) - type TFHelper_0123456789876543210Sym2 :: a -> T x b -> T x a + type TFHelper_0123456789876543210Sym2 :: forall a x b. a + -> T x b -> T x a type family TFHelper_0123456789876543210Sym2 @a @x @b (a0123456789876543210 :: a) (a0123456789876543210 :: T x b) :: T x a where TFHelper_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = TFHelper_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PFunctor (T x) where type Fmap a a = Apply (Apply Fmap_0123456789876543210Sym0 a) a type (<$) a a = Apply (Apply TFHelper_0123456789876543210Sym0 a) a - type family Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where - Lambda_0123456789876543210 _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = MemptySym0 - data Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where + Lambda_0123456789876543210 x _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = MemptySym0 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - type family Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type family Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where - Lambda_0123456789876543210 _f_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = MemptySym0 - data Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_0123456789876543210 where + Lambda_0123456789876543210 x _f_0123456789876543210 a_0123456789876543210 n_0123456789876543210 = MemptySym0 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - type family Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 - type FoldMap_0123456789876543210 :: (~>) a m -> T x a -> m + type family Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n_01234567898765432100123456789876543210 + type FoldMap_0123456789876543210 :: forall a m x. (~>) a m + -> T x a -> m type family FoldMap_0123456789876543210 @a @m @x (a :: (~>) a m) (a :: T x a) :: m where - FoldMap_0123456789876543210 _f_0123456789876543210 (MkT1 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) = Apply (Apply MappendSym0 (Apply (Lambda_0123456789876543210Sym0 _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210)) (Apply (Apply MappendSym0 (Apply _f_0123456789876543210 a_0123456789876543210)) (Apply (Apply MappendSym0 (Apply (Apply FoldMapSym0 _f_0123456789876543210) a_0123456789876543210)) (Apply (Apply FoldMapSym0 (Apply FoldMapSym0 _f_0123456789876543210)) a_0123456789876543210))) - FoldMap_0123456789876543210 _f_0123456789876543210 (MkT2 a_0123456789876543210) = Apply (Lambda_0123456789876543210Sym0 _f_0123456789876543210 a_0123456789876543210) a_0123456789876543210 - type FoldMap_0123456789876543210Sym0 :: (~>) ((~>) a m) ((~>) (T x a) m) + FoldMap_0123456789876543210 @a @m @x (_f_0123456789876543210 :: (~>) a m) (MkT1 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: T x a) = Apply (Apply MappendSym0 (Apply (Lambda_0123456789876543210Sym0 x _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210)) (Apply (Apply MappendSym0 (Apply _f_0123456789876543210 a_0123456789876543210)) (Apply (Apply MappendSym0 (Apply (Apply FoldMapSym0 _f_0123456789876543210) a_0123456789876543210)) (Apply (Apply FoldMapSym0 (Apply FoldMapSym0 _f_0123456789876543210)) a_0123456789876543210))) + FoldMap_0123456789876543210 @a @m @x (_f_0123456789876543210 :: (~>) a m) (MkT2 a_0123456789876543210 :: T x a) = Apply (Lambda_0123456789876543210Sym0 x _f_0123456789876543210 a_0123456789876543210) a_0123456789876543210 + type FoldMap_0123456789876543210Sym0 :: forall a + m + x. (~>) ((~>) a m) ((~>) (T x a) m) data FoldMap_0123456789876543210Sym0 :: (~>) ((~>) a m) ((~>) (T x a) m) where FoldMap_0123456789876543210Sym0KindInference :: SameKind (Apply FoldMap_0123456789876543210Sym0 arg) (FoldMap_0123456789876543210Sym1 arg) => @@ -211,7 +223,8 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings FoldMap_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) FoldMap_0123456789876543210Sym0KindInference ()) - type FoldMap_0123456789876543210Sym1 :: (~>) a m -> (~>) (T x a) m + type FoldMap_0123456789876543210Sym1 :: forall a m x. (~>) a m + -> (~>) (T x a) m data FoldMap_0123456789876543210Sym1 (a0123456789876543210 :: (~>) a m) :: (~>) (T x a) m where FoldMap_0123456789876543210Sym1KindInference :: SameKind (Apply (FoldMap_0123456789876543210Sym1 a0123456789876543210) arg) (FoldMap_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -220,115 +233,118 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (FoldMap_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) FoldMap_0123456789876543210Sym1KindInference ()) - type FoldMap_0123456789876543210Sym2 :: (~>) a m -> T x a -> m + type FoldMap_0123456789876543210Sym2 :: forall a m x. (~>) a m + -> T x a -> m type family FoldMap_0123456789876543210Sym2 @a @m @x (a0123456789876543210 :: (~>) a m) (a0123456789876543210 :: T x a) :: m where FoldMap_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = FoldMap_0123456789876543210 a0123456789876543210 a0123456789876543210 - type family Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_0123456789876543210 n2_0123456789876543210 where - Lambda_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 = n2_0123456789876543210 - data Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_0123456789876543210 n2_0123456789876543210 where + Lambda_0123456789876543210 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 = n2_0123456789876543210 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n1_01234567898765432100123456789876543210 = Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n1_01234567898765432100123456789876543210 = Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - data Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + data Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym1KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym1KindInference ()) - type family Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - type family Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_0123456789876543210 n2_0123456789876543210 where - Lambda_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 = Apply (Apply (Apply FoldrSym0 _f_0123456789876543210) n2_0123456789876543210) n1_0123456789876543210 - data Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_0123456789876543210 n2_0123456789876543210 where + Lambda_0123456789876543210 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 = Apply (Apply (Apply FoldrSym0 _f_0123456789876543210) n2_0123456789876543210) n1_0123456789876543210 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n1_01234567898765432100123456789876543210 = Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n1_01234567898765432100123456789876543210 = Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - data Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + data Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym1KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym1KindInference ()) - type family Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - type family Lambda_0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_0123456789876543210 n2_0123456789876543210 where - Lambda_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 = Apply (Apply (Apply FoldrSym0 _f_0123456789876543210) n2_0123456789876543210) n1_0123456789876543210 - data Lambda_0123456789876543210Sym0 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_0123456789876543210 n2_0123456789876543210 where + Lambda_0123456789876543210 x n1_0123456789876543210 n2_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 = Apply (Apply (Apply FoldrSym0 _f_0123456789876543210) n2_0123456789876543210) n1_0123456789876543210 + data Lambda_0123456789876543210Sym0 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n1_01234567898765432100123456789876543210 = Lambda_0123456789876543210Sym1 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n1_01234567898765432100123456789876543210 = Lambda_0123456789876543210Sym1 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - data Lambda_0123456789876543210Sym1 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + data Lambda_0123456789876543210Sym1 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym1 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym2 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym1 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym1 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym1 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym1KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym1 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym2 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym1 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym1 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym1 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym1KindInference ()) - type family Lambda_0123456789876543210Sym2 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym2 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - type family Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_0123456789876543210 n2_0123456789876543210 where - Lambda_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 = Apply (Apply (Apply FoldrSym0 (Lambda_0123456789876543210Sym0 n1_0123456789876543210 n2_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210)) n2_0123456789876543210) n1_0123456789876543210 - data Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210Sym2 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym2 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_0123456789876543210 n2_0123456789876543210 where + Lambda_0123456789876543210 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 = Apply (Apply (Apply FoldrSym0 (Lambda_0123456789876543210Sym0 x n1_0123456789876543210 n2_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210)) n2_0123456789876543210) n1_0123456789876543210 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n1_01234567898765432100123456789876543210 = Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n1_01234567898765432100123456789876543210 = Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - data Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + data Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym1KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym1KindInference ()) - type family Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - type family Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_0123456789876543210 n2_0123456789876543210 where - Lambda_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 = n2_0123456789876543210 - data Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + type family Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_0123456789876543210 n2_0123456789876543210 where + Lambda_0123456789876543210 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 n1_0123456789876543210 n2_0123456789876543210 = n2_0123456789876543210 + data Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n1_01234567898765432100123456789876543210 = Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) n1_01234567898765432100123456789876543210 = Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - data Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + data Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym1KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 arg) => - Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym1 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) where + Lambda_0123456789876543210Sym1KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) arg) (Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 arg) => + Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym1 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym1KindInference ()) - type family Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where - Lambda_0123456789876543210Sym2 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 - type Foldr_0123456789876543210 :: (~>) a ((~>) b b) - -> b -> T x a -> b + type family Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 where + Lambda_0123456789876543210Sym2 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 _f_01234567898765432100123456789876543210 _z_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 n1_01234567898765432100123456789876543210 n2_01234567898765432100123456789876543210 + type Foldr_0123456789876543210 :: forall a b x. (~>) a ((~>) b b) + -> b -> T x a -> b type family Foldr_0123456789876543210 @a @b @x (a :: (~>) a ((~>) b b)) (a :: b) (a :: T x a) :: b where - Foldr_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 (MkT1 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) = Apply (Apply (Lambda_0123456789876543210Sym0 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210) (Apply (Apply _f_0123456789876543210 a_0123456789876543210) (Apply (Apply (Lambda_0123456789876543210Sym0 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210) (Apply (Apply (Lambda_0123456789876543210Sym0 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210) _z_0123456789876543210))) - Foldr_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 (MkT2 a_0123456789876543210) = Apply (Apply (Lambda_0123456789876543210Sym0 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210) a_0123456789876543210) _z_0123456789876543210 - type Foldr_0123456789876543210Sym0 :: (~>) ((~>) a ((~>) b b)) ((~>) b ((~>) (T x a) b)) + Foldr_0123456789876543210 @a @b @x (_f_0123456789876543210 :: (~>) a ((~>) b b)) (_z_0123456789876543210 :: b) (MkT1 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: T x a) = Apply (Apply (Lambda_0123456789876543210Sym0 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210) (Apply (Apply _f_0123456789876543210 a_0123456789876543210) (Apply (Apply (Lambda_0123456789876543210Sym0 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210) (Apply (Apply (Lambda_0123456789876543210Sym0 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210) _z_0123456789876543210))) + Foldr_0123456789876543210 @a @b @x (_f_0123456789876543210 :: (~>) a ((~>) b b)) (_z_0123456789876543210 :: b) (MkT2 a_0123456789876543210 :: T x a) = Apply (Apply (Lambda_0123456789876543210Sym0 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210) a_0123456789876543210) _z_0123456789876543210 + type Foldr_0123456789876543210Sym0 :: forall a + b + x. (~>) ((~>) a ((~>) b b)) ((~>) b ((~>) (T x a) b)) data Foldr_0123456789876543210Sym0 :: (~>) ((~>) a ((~>) b b)) ((~>) b ((~>) (T x a) b)) where Foldr_0123456789876543210Sym0KindInference :: SameKind (Apply Foldr_0123456789876543210Sym0 arg) (Foldr_0123456789876543210Sym1 arg) => @@ -337,8 +353,9 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Foldr_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Foldr_0123456789876543210Sym0KindInference ()) - type Foldr_0123456789876543210Sym1 :: (~>) a ((~>) b b) - -> (~>) b ((~>) (T x a) b) + type Foldr_0123456789876543210Sym1 :: forall a + b + x. (~>) a ((~>) b b) -> (~>) b ((~>) (T x a) b) data Foldr_0123456789876543210Sym1 (a0123456789876543210 :: (~>) a ((~>) b b)) :: (~>) b ((~>) (T x a) b) where Foldr_0123456789876543210Sym1KindInference :: SameKind (Apply (Foldr_0123456789876543210Sym1 a0123456789876543210) arg) (Foldr_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -347,8 +364,9 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Foldr_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Foldr_0123456789876543210Sym1KindInference ()) - type Foldr_0123456789876543210Sym2 :: (~>) a ((~>) b b) - -> b -> (~>) (T x a) b + type Foldr_0123456789876543210Sym2 :: forall a + b + x. (~>) a ((~>) b b) -> b -> (~>) (T x a) b data Foldr_0123456789876543210Sym2 (a0123456789876543210 :: (~>) a ((~>) b b)) (a0123456789876543210 :: b) :: (~>) (T x a) b where Foldr_0123456789876543210Sym2KindInference :: SameKind (Apply (Foldr_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) arg) (Foldr_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 arg) => @@ -357,19 +375,23 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Foldr_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Foldr_0123456789876543210Sym2KindInference ()) - type Foldr_0123456789876543210Sym3 :: (~>) a ((~>) b b) - -> b -> T x a -> b + type Foldr_0123456789876543210Sym3 :: forall a + b + x. (~>) a ((~>) b b) -> b -> T x a -> b type family Foldr_0123456789876543210Sym3 @a @b @x (a0123456789876543210 :: (~>) a ((~>) b b)) (a0123456789876543210 :: b) (a0123456789876543210 :: T x a) :: b where Foldr_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 a0123456789876543210 = Foldr_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210 instance PFoldable (T x) where type FoldMap a a = Apply (Apply FoldMap_0123456789876543210Sym0 a) a type Foldr a a a = Apply (Apply (Apply Foldr_0123456789876543210Sym0 a) a) a - type Traverse_0123456789876543210 :: (~>) a (f b) - -> T x a -> f (T x b) + type Traverse_0123456789876543210 :: forall a f b x. (~>) a (f b) + -> T x a -> f (T x b) type family Traverse_0123456789876543210 @a @f @b @x (a :: (~>) a (f b)) (a :: T x a) :: f (T x b) where - Traverse_0123456789876543210 _f_0123456789876543210 (MkT1 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) = Apply (Apply (<*>@#@$) (Apply (Apply (<*>@#@$) (Apply (Apply (Apply LiftA2Sym0 MkT1Sym0) (Apply PureSym0 a_0123456789876543210)) (Apply _f_0123456789876543210 a_0123456789876543210))) (Apply (Apply TraverseSym0 _f_0123456789876543210) a_0123456789876543210))) (Apply (Apply TraverseSym0 (Apply TraverseSym0 _f_0123456789876543210)) a_0123456789876543210) - Traverse_0123456789876543210 _f_0123456789876543210 (MkT2 a_0123456789876543210) = Apply (Apply FmapSym0 MkT2Sym0) (Apply PureSym0 a_0123456789876543210) - type Traverse_0123456789876543210Sym0 :: (~>) ((~>) a (f b)) ((~>) (T x a) (f (T x b))) + Traverse_0123456789876543210 @a @f @b @x (_f_0123456789876543210 :: (~>) a (f b)) (MkT1 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: T x a) = Apply (Apply (<*>@#@$) (Apply (Apply (<*>@#@$) (Apply (Apply (Apply LiftA2Sym0 MkT1Sym0) (Apply PureSym0 a_0123456789876543210)) (Apply _f_0123456789876543210 a_0123456789876543210))) (Apply (Apply TraverseSym0 _f_0123456789876543210) a_0123456789876543210))) (Apply (Apply TraverseSym0 (Apply TraverseSym0 _f_0123456789876543210)) a_0123456789876543210) + Traverse_0123456789876543210 @a @f @b @x (_f_0123456789876543210 :: (~>) a (f b)) (MkT2 a_0123456789876543210 :: T x a) = Apply (Apply FmapSym0 MkT2Sym0) (Apply PureSym0 a_0123456789876543210) + type Traverse_0123456789876543210Sym0 :: forall a + f + b + x. (~>) ((~>) a (f b)) ((~>) (T x a) (f (T x b))) data Traverse_0123456789876543210Sym0 :: (~>) ((~>) a (f b)) ((~>) (T x a) (f (T x b))) where Traverse_0123456789876543210Sym0KindInference :: SameKind (Apply Traverse_0123456789876543210Sym0 arg) (Traverse_0123456789876543210Sym1 arg) => @@ -378,8 +400,10 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Traverse_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Traverse_0123456789876543210Sym0KindInference ()) - type Traverse_0123456789876543210Sym1 :: (~>) a (f b) - -> (~>) (T x a) (f (T x b)) + type Traverse_0123456789876543210Sym1 :: forall a + f + b + x. (~>) a (f b) -> (~>) (T x a) (f (T x b)) data Traverse_0123456789876543210Sym1 (a0123456789876543210 :: (~>) a (f b)) :: (~>) (T x a) (f (T x b)) where Traverse_0123456789876543210Sym1KindInference :: SameKind (Apply (Traverse_0123456789876543210Sym1 a0123456789876543210) arg) (Traverse_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -388,17 +412,21 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Traverse_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Traverse_0123456789876543210Sym1KindInference ()) - type Traverse_0123456789876543210Sym2 :: (~>) a (f b) - -> T x a -> f (T x b) + type Traverse_0123456789876543210Sym2 :: forall a + f + b + x. (~>) a (f b) -> T x a -> f (T x b) type family Traverse_0123456789876543210Sym2 @a @f @b @x (a0123456789876543210 :: (~>) a (f b)) (a0123456789876543210 :: T x a) :: f (T x b) where Traverse_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Traverse_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PTraversable (T x) where type Traverse a a = Apply (Apply Traverse_0123456789876543210Sym0 a) a type family Case_0123456789876543210 v_01234567898765432100123456789876543210 t where - type Fmap_0123456789876543210 :: (~>) a b -> Empty a -> Empty b + type Fmap_0123456789876543210 :: forall a b. (~>) a b + -> Empty a -> Empty b type family Fmap_0123456789876543210 @a @b (a :: (~>) a b) (a :: Empty a) :: Empty b where - Fmap_0123456789876543210 _ v_0123456789876543210 = Case_0123456789876543210 v_0123456789876543210 v_0123456789876543210 - type Fmap_0123456789876543210Sym0 :: (~>) ((~>) a b) ((~>) (Empty a) (Empty b)) + Fmap_0123456789876543210 @a @b _ v_0123456789876543210 = Case_0123456789876543210 v_0123456789876543210 v_0123456789876543210 + type Fmap_0123456789876543210Sym0 :: forall a + b. (~>) ((~>) a b) ((~>) (Empty a) (Empty b)) data Fmap_0123456789876543210Sym0 :: (~>) ((~>) a b) ((~>) (Empty a) (Empty b)) where Fmap_0123456789876543210Sym0KindInference :: SameKind (Apply Fmap_0123456789876543210Sym0 arg) (Fmap_0123456789876543210Sym1 arg) => @@ -407,8 +435,8 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Fmap_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Fmap_0123456789876543210Sym0KindInference ()) - type Fmap_0123456789876543210Sym1 :: (~>) a b - -> (~>) (Empty a) (Empty b) + type Fmap_0123456789876543210Sym1 :: forall a b. (~>) a b + -> (~>) (Empty a) (Empty b) data Fmap_0123456789876543210Sym1 (a0123456789876543210 :: (~>) a b) :: (~>) (Empty a) (Empty b) where Fmap_0123456789876543210Sym1KindInference :: SameKind (Apply (Fmap_0123456789876543210Sym1 a0123456789876543210) arg) (Fmap_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -417,14 +445,17 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Fmap_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Fmap_0123456789876543210Sym1KindInference ()) - type Fmap_0123456789876543210Sym2 :: (~>) a b -> Empty a -> Empty b + type Fmap_0123456789876543210Sym2 :: forall a b. (~>) a b + -> Empty a -> Empty b type family Fmap_0123456789876543210Sym2 @a @b (a0123456789876543210 :: (~>) a b) (a0123456789876543210 :: Empty a) :: Empty b where Fmap_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Fmap_0123456789876543210 a0123456789876543210 a0123456789876543210 type family Case_0123456789876543210 v_01234567898765432100123456789876543210 t where - type TFHelper_0123456789876543210 :: a -> Empty b -> Empty a + type TFHelper_0123456789876543210 :: forall a b. a + -> Empty b -> Empty a type family TFHelper_0123456789876543210 @a @b (a :: a) (a :: Empty b) :: Empty a where - TFHelper_0123456789876543210 _ v_0123456789876543210 = Case_0123456789876543210 v_0123456789876543210 v_0123456789876543210 - type TFHelper_0123456789876543210Sym0 :: (~>) a ((~>) (Empty b) (Empty a)) + TFHelper_0123456789876543210 @a @b _ v_0123456789876543210 = Case_0123456789876543210 v_0123456789876543210 v_0123456789876543210 + type TFHelper_0123456789876543210Sym0 :: forall a + b. (~>) a ((~>) (Empty b) (Empty a)) data TFHelper_0123456789876543210Sym0 :: (~>) a ((~>) (Empty b) (Empty a)) where TFHelper_0123456789876543210Sym0KindInference :: SameKind (Apply TFHelper_0123456789876543210Sym0 arg) (TFHelper_0123456789876543210Sym1 arg) => @@ -433,8 +464,8 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings TFHelper_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym0KindInference ()) - type TFHelper_0123456789876543210Sym1 :: a - -> (~>) (Empty b) (Empty a) + type TFHelper_0123456789876543210Sym1 :: forall a b. a + -> (~>) (Empty b) (Empty a) data TFHelper_0123456789876543210Sym1 (a0123456789876543210 :: a) :: (~>) (Empty b) (Empty a) where TFHelper_0123456789876543210Sym1KindInference :: SameKind (Apply (TFHelper_0123456789876543210Sym1 a0123456789876543210) arg) (TFHelper_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -443,16 +474,19 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (TFHelper_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym1KindInference ()) - type TFHelper_0123456789876543210Sym2 :: a -> Empty b -> Empty a + type TFHelper_0123456789876543210Sym2 :: forall a b. a + -> Empty b -> Empty a type family TFHelper_0123456789876543210Sym2 @a @b (a0123456789876543210 :: a) (a0123456789876543210 :: Empty b) :: Empty a where TFHelper_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = TFHelper_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PFunctor Empty where type Fmap a a = Apply (Apply Fmap_0123456789876543210Sym0 a) a type (<$) a a = Apply (Apply TFHelper_0123456789876543210Sym0 a) a - type FoldMap_0123456789876543210 :: (~>) a m -> Empty a -> m + type FoldMap_0123456789876543210 :: forall a m. (~>) a m + -> Empty a -> m type family FoldMap_0123456789876543210 @a @m (a :: (~>) a m) (a :: Empty a) :: m where - FoldMap_0123456789876543210 _ _ = MemptySym0 - type FoldMap_0123456789876543210Sym0 :: (~>) ((~>) a m) ((~>) (Empty a) m) + FoldMap_0123456789876543210 @a @m _ _ = MemptySym0 + type FoldMap_0123456789876543210Sym0 :: forall a + m. (~>) ((~>) a m) ((~>) (Empty a) m) data FoldMap_0123456789876543210Sym0 :: (~>) ((~>) a m) ((~>) (Empty a) m) where FoldMap_0123456789876543210Sym0KindInference :: SameKind (Apply FoldMap_0123456789876543210Sym0 arg) (FoldMap_0123456789876543210Sym1 arg) => @@ -461,8 +495,8 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings FoldMap_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) FoldMap_0123456789876543210Sym0KindInference ()) - type FoldMap_0123456789876543210Sym1 :: (~>) a m - -> (~>) (Empty a) m + type FoldMap_0123456789876543210Sym1 :: forall a m. (~>) a m + -> (~>) (Empty a) m data FoldMap_0123456789876543210Sym1 (a0123456789876543210 :: (~>) a m) :: (~>) (Empty a) m where FoldMap_0123456789876543210Sym1KindInference :: SameKind (Apply (FoldMap_0123456789876543210Sym1 a0123456789876543210) arg) (FoldMap_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -471,17 +505,20 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (FoldMap_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) FoldMap_0123456789876543210Sym1KindInference ()) - type FoldMap_0123456789876543210Sym2 :: (~>) a m -> Empty a -> m + type FoldMap_0123456789876543210Sym2 :: forall a m. (~>) a m + -> Empty a -> m type family FoldMap_0123456789876543210Sym2 @a @m (a0123456789876543210 :: (~>) a m) (a0123456789876543210 :: Empty a) :: m where FoldMap_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = FoldMap_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PFoldable Empty where type FoldMap a a = Apply (Apply FoldMap_0123456789876543210Sym0 a) a type family Case_0123456789876543210 v_01234567898765432100123456789876543210 t where - type Traverse_0123456789876543210 :: (~>) a (f b) - -> Empty a -> f (Empty b) + type Traverse_0123456789876543210 :: forall a f b. (~>) a (f b) + -> Empty a -> f (Empty b) type family Traverse_0123456789876543210 @a @f @b (a :: (~>) a (f b)) (a :: Empty a) :: f (Empty b) where - Traverse_0123456789876543210 _ v_0123456789876543210 = Apply PureSym0 (Case_0123456789876543210 v_0123456789876543210 v_0123456789876543210) - type Traverse_0123456789876543210Sym0 :: (~>) ((~>) a (f b)) ((~>) (Empty a) (f (Empty b))) + Traverse_0123456789876543210 @a @f @b _ v_0123456789876543210 = Apply PureSym0 (Case_0123456789876543210 v_0123456789876543210 v_0123456789876543210) + type Traverse_0123456789876543210Sym0 :: forall a + f + b. (~>) ((~>) a (f b)) ((~>) (Empty a) (f (Empty b))) data Traverse_0123456789876543210Sym0 :: (~>) ((~>) a (f b)) ((~>) (Empty a) (f (Empty b))) where Traverse_0123456789876543210Sym0KindInference :: SameKind (Apply Traverse_0123456789876543210Sym0 arg) (Traverse_0123456789876543210Sym1 arg) => @@ -490,8 +527,8 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Traverse_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Traverse_0123456789876543210Sym0KindInference ()) - type Traverse_0123456789876543210Sym1 :: (~>) a (f b) - -> (~>) (Empty a) (f (Empty b)) + type Traverse_0123456789876543210Sym1 :: forall a f b. (~>) a (f b) + -> (~>) (Empty a) (f (Empty b)) data Traverse_0123456789876543210Sym1 (a0123456789876543210 :: (~>) a (f b)) :: (~>) (Empty a) (f (Empty b)) where Traverse_0123456789876543210Sym1KindInference :: SameKind (Apply (Traverse_0123456789876543210Sym1 a0123456789876543210) arg) (Traverse_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -500,8 +537,8 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Traverse_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Traverse_0123456789876543210Sym1KindInference ()) - type Traverse_0123456789876543210Sym2 :: (~>) a (f b) - -> Empty a -> f (Empty b) + type Traverse_0123456789876543210Sym2 :: forall a f b. (~>) a (f b) + -> Empty a -> f (Empty b) type family Traverse_0123456789876543210Sym2 @a @f @b (a0123456789876543210 :: (~>) a (f b)) (a0123456789876543210 :: Empty a) :: f (Empty b) where Traverse_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Traverse_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PTraversable Empty where @@ -548,19 +585,6 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations fromSing x = case x of {} toSing x = SomeSing (case x of {}) instance SFunctor (T x) where - sFmap :: - forall (a :: Type) - (b :: Type) - (t1 :: (~>) a b) - (t2 :: T x a). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (FmapSym0 :: TyFun ((~>) a b) ((~>) (T x a) (T x b)) - -> Type) t1) t2) - (%<$) :: - forall (a :: Type) (b :: Type) (t1 :: a) (t2 :: T x b). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((<$@#@$) :: TyFun a ((~>) (T x b) (T x a)) - -> Type) t1) t2) sFmap (_sf_0123456789876543210 :: Sing _f_0123456789876543210) (SMkT1 (sA_0123456789876543210 :: Sing a_0123456789876543210) @@ -574,7 +598,7 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations (singFun4 @MkT1Sym0 SMkT1) (applySing (singFun1 - @(Lambda_0123456789876543210Sym0 _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (\ sN_0123456789876543210 -> case sN_0123456789876543210 of (_ :: Sing n_0123456789876543210) -> sN_0123456789876543210)) @@ -595,7 +619,7 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations (singFun1 @MkT2Sym0 SMkT2) (applySing (singFun1 - @(Lambda_0123456789876543210Sym0 _f_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _f_0123456789876543210 a_0123456789876543210) (\ sN_0123456789876543210 -> case sN_0123456789876543210 of (_ :: Sing n_0123456789876543210) -> sN_0123456789876543210)) @@ -613,14 +637,14 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations (singFun4 @MkT1Sym0 SMkT1) (applySing (singFun1 - @(Lambda_0123456789876543210Sym0 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (\ sN_0123456789876543210 -> case sN_0123456789876543210 of (_ :: Sing n_0123456789876543210) -> sN_0123456789876543210)) sA_0123456789876543210)) (applySing (singFun1 - @(Lambda_0123456789876543210Sym0 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (\ sN_0123456789876543210 -> case sN_0123456789876543210 of (_ :: Sing n_0123456789876543210) -> _sz_0123456789876543210)) @@ -640,31 +664,12 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations (singFun1 @MkT2Sym0 SMkT2) (applySing (singFun1 - @(Lambda_0123456789876543210Sym0 _z_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _z_0123456789876543210 a_0123456789876543210) (\ sN_0123456789876543210 -> case sN_0123456789876543210 of (_ :: Sing n_0123456789876543210) -> sN_0123456789876543210)) sA_0123456789876543210) instance SFoldable (T x) where - sFoldMap :: - forall (a :: Type) - (m :: Type) - (t1 :: (~>) a m) - (t2 :: T x a). SMonoid m => - Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (FoldMapSym0 :: TyFun ((~>) a m) ((~>) (T x a) m) - -> Type) t1) t2) - sFoldr :: - forall (a :: Type) - (b :: Type) - (t1 :: (~>) a ((~>) b b)) - (t2 :: b) - (t3 :: T x a). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (FoldrSym0 :: TyFun ((~>) a ((~>) b b)) ((~>) b ((~>) (T x a) b)) - -> Type) t1) t2) t3) sFoldMap (_sf_0123456789876543210 :: Sing _f_0123456789876543210) (SMkT1 (sA_0123456789876543210 :: Sing a_0123456789876543210) @@ -676,7 +681,7 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations (singFun2 @MappendSym0 sMappend) (applySing (singFun1 - @(Lambda_0123456789876543210Sym0 _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _f_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (\ sN_0123456789876543210 -> case sN_0123456789876543210 of (_ :: Sing n_0123456789876543210) -> sMempty)) @@ -703,7 +708,7 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations (SMkT2 (sA_0123456789876543210 :: Sing a_0123456789876543210)) = applySing (singFun1 - @(Lambda_0123456789876543210Sym0 _f_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _f_0123456789876543210 a_0123456789876543210) (\ sN_0123456789876543210 -> case sN_0123456789876543210 of (_ :: Sing n_0123456789876543210) -> sMempty)) @@ -718,7 +723,7 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations = applySing (applySing (singFun2 - @(Lambda_0123456789876543210Sym0 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (\ sN1_0123456789876543210 sN2_0123456789876543210 -> case (,) sN1_0123456789876543210 sN2_0123456789876543210 of (,) (_ :: Sing n1_0123456789876543210) @@ -730,7 +735,7 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations (applySing (applySing (singFun2 - @(Lambda_0123456789876543210Sym0 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (\ sN1_0123456789876543210 sN2_0123456789876543210 -> case (,) sN1_0123456789876543210 sN2_0123456789876543210 of (,) (_ :: Sing n1_0123456789876543210) @@ -745,7 +750,7 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations (applySing (applySing (singFun2 - @(Lambda_0123456789876543210Sym0 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (\ sN1_0123456789876543210 sN2_0123456789876543210 -> case (,) sN1_0123456789876543210 sN2_0123456789876543210 of (,) (_ :: Sing n1_0123456789876543210) @@ -755,7 +760,7 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations (applySing (singFun3 @FoldrSym0 sFoldr) (singFun2 - @(Lambda_0123456789876543210Sym0 n1_0123456789876543210 n2_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x n1_0123456789876543210 n2_0123456789876543210 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (\ sN1_0123456789876543210 sN2_0123456789876543210 -> case @@ -783,7 +788,7 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations = applySing (applySing (singFun2 - @(Lambda_0123456789876543210Sym0 _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210) + @(Lambda_0123456789876543210Sym0 x _f_0123456789876543210 _z_0123456789876543210 a_0123456789876543210) (\ sN1_0123456789876543210 sN2_0123456789876543210 -> case (,) sN1_0123456789876543210 sN2_0123456789876543210 of (,) (_ :: Sing n1_0123456789876543210) @@ -792,16 +797,6 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations sA_0123456789876543210) _sz_0123456789876543210 instance STraversable (T x) where - sTraverse :: - forall (a :: Type) - (f :: Type -> Type) - (b :: Type) - (t1 :: (~>) a (f b)) - (t2 :: T x a). SApplicative f => - Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (TraverseSym0 :: TyFun ((~>) a (f b)) ((~>) (T x a) (f (T x b))) - -> Type) t1) t2) sTraverse (_sf_0123456789876543210 :: Sing _f_0123456789876543210) (SMkT1 (sA_0123456789876543210 :: Sing a_0123456789876543210) @@ -837,19 +832,6 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations (applySing (singFun2 @FmapSym0 sFmap) (singFun1 @MkT2Sym0 SMkT2)) (applySing (singFun1 @PureSym0 sPure) sA_0123456789876543210) instance SFunctor Empty where - sFmap :: - forall (a :: Type) - (b :: Type) - (t1 :: (~>) a b) - (t2 :: Empty a). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (FmapSym0 :: TyFun ((~>) a b) ((~>) (Empty a) (Empty b)) - -> Type) t1) t2) - (%<$) :: - forall (a :: Type) (b :: Type) (t1 :: a) (t2 :: Empty b). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((<$@#@$) :: TyFun a ((~>) (Empty b) (Empty a)) - -> Type) t1) t2) sFmap _ (sV_0123456789876543210 :: Sing v_0123456789876543210) = id @(Sing (Case_0123456789876543210 v_0123456789876543210 v_0123456789876543210)) @@ -859,27 +841,8 @@ Singletons/FunctorLikeDeriving.hs:(0,0)-(0,0): Splicing declarations @(Sing (Case_0123456789876543210 v_0123456789876543210 v_0123456789876543210)) (case sV_0123456789876543210 of {}) instance SFoldable Empty where - sFoldMap :: - forall (a :: Type) - (m :: Type) - (t1 :: (~>) a m) - (t2 :: Empty a). SMonoid m => - Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (FoldMapSym0 :: TyFun ((~>) a m) ((~>) (Empty a) m) - -> Type) t1) t2) sFoldMap _ _ = sMempty instance STraversable Empty where - sTraverse :: - forall (a :: Type) - (f :: Type -> Type) - (b :: Type) - (t1 :: (~>) a (f b)) - (t2 :: Empty a). SApplicative f => - Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (TraverseSym0 :: TyFun ((~>) a (f b)) ((~>) (Empty a) (f (Empty b))) - -> Type) t1) t2) sTraverse _ (sV_0123456789876543210 :: Sing v_0123456789876543210) = applySing (singFun1 @PureSym0 sPure) diff --git a/singletons-base/tests/compile-and-dump/Singletons/Maybe.golden b/singletons-base/tests/compile-and-dump/Singletons/Maybe.golden index 2a9a04c4..01e697df 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/Maybe.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/Maybe.golden @@ -21,13 +21,14 @@ Singletons/Maybe.hs:(0,0)-(0,0): Splicing declarations type JustSym1 :: forall a. a -> Maybe a type family JustSym1 @a (a0123456789876543210 :: a) :: Maybe a where JustSym1 a0123456789876543210 = Just a0123456789876543210 - type TFHelper_0123456789876543210 :: Maybe a -> Maybe a -> Bool + type TFHelper_0123456789876543210 :: forall a. Maybe a + -> Maybe a -> Bool type family TFHelper_0123456789876543210 @a (a :: Maybe a) (a :: Maybe a) :: Bool where - TFHelper_0123456789876543210 Nothing Nothing = TrueSym0 - TFHelper_0123456789876543210 Nothing (Just _) = FalseSym0 - TFHelper_0123456789876543210 (Just _) Nothing = FalseSym0 - TFHelper_0123456789876543210 (Just a_0123456789876543210) (Just b_0123456789876543210) = Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210 - type TFHelper_0123456789876543210Sym0 :: (~>) (Maybe a) ((~>) (Maybe a) Bool) + TFHelper_0123456789876543210 @a (Nothing :: Maybe a) (Nothing :: Maybe a) = TrueSym0 + TFHelper_0123456789876543210 @a (Nothing :: Maybe a) (Just _ :: Maybe a) = FalseSym0 + TFHelper_0123456789876543210 @a (Just _ :: Maybe a) (Nothing :: Maybe a) = FalseSym0 + TFHelper_0123456789876543210 @a (Just a_0123456789876543210 :: Maybe a) (Just b_0123456789876543210 :: Maybe a) = Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210 + type TFHelper_0123456789876543210Sym0 :: forall a. (~>) (Maybe a) ((~>) (Maybe a) Bool) data TFHelper_0123456789876543210Sym0 :: (~>) (Maybe a) ((~>) (Maybe a) Bool) where TFHelper_0123456789876543210Sym0KindInference :: SameKind (Apply TFHelper_0123456789876543210Sym0 arg) (TFHelper_0123456789876543210Sym1 arg) => @@ -36,8 +37,8 @@ Singletons/Maybe.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings TFHelper_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym0KindInference ()) - type TFHelper_0123456789876543210Sym1 :: Maybe a - -> (~>) (Maybe a) Bool + type TFHelper_0123456789876543210Sym1 :: forall a. Maybe a + -> (~>) (Maybe a) Bool data TFHelper_0123456789876543210Sym1 (a0123456789876543210 :: Maybe a) :: (~>) (Maybe a) Bool where TFHelper_0123456789876543210Sym1KindInference :: SameKind (Apply (TFHelper_0123456789876543210Sym1 a0123456789876543210) arg) (TFHelper_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -46,17 +47,19 @@ Singletons/Maybe.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (TFHelper_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym1KindInference ()) - type TFHelper_0123456789876543210Sym2 :: Maybe a -> Maybe a -> Bool + type TFHelper_0123456789876543210Sym2 :: forall a. Maybe a + -> Maybe a -> Bool type family TFHelper_0123456789876543210Sym2 @a (a0123456789876543210 :: Maybe a) (a0123456789876543210 :: Maybe a) :: Bool where TFHelper_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = TFHelper_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PEq (Maybe a) where type (==) a a = Apply (Apply TFHelper_0123456789876543210Sym0 a) a - type ShowsPrec_0123456789876543210 :: GHC.Num.Natural.Natural - -> Maybe a -> GHC.Types.Symbol -> GHC.Types.Symbol + type ShowsPrec_0123456789876543210 :: forall a. GHC.Num.Natural.Natural + -> Maybe a + -> GHC.Types.Symbol -> GHC.Types.Symbol type family ShowsPrec_0123456789876543210 @a (a :: GHC.Num.Natural.Natural) (a :: Maybe a) (a :: GHC.Types.Symbol) :: GHC.Types.Symbol where - ShowsPrec_0123456789876543210 _ Nothing a_0123456789876543210 = Apply (Apply ShowStringSym0 "Nothing") a_0123456789876543210 - ShowsPrec_0123456789876543210 p_0123456789876543210 (Just arg_0123456789876543210) a_0123456789876543210 = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "Just ")) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))) a_0123456789876543210 - type ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (Maybe a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) + ShowsPrec_0123456789876543210 @a (_ :: GHC.Num.Natural.Natural) (Nothing :: Maybe a) (a_0123456789876543210 :: GHC.Types.Symbol) = Apply (Apply ShowStringSym0 "Nothing") a_0123456789876543210 + ShowsPrec_0123456789876543210 @a (p_0123456789876543210 :: GHC.Num.Natural.Natural) (Just arg_0123456789876543210 :: Maybe a) (a_0123456789876543210 :: GHC.Types.Symbol) = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "Just ")) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))) a_0123456789876543210 + type ShowsPrec_0123456789876543210Sym0 :: forall a. (~>) GHC.Num.Natural.Natural ((~>) (Maybe a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) data ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (Maybe a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) where ShowsPrec_0123456789876543210Sym0KindInference :: SameKind (Apply ShowsPrec_0123456789876543210Sym0 arg) (ShowsPrec_0123456789876543210Sym1 arg) => @@ -65,8 +68,8 @@ Singletons/Maybe.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings ShowsPrec_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym0KindInference ()) - type ShowsPrec_0123456789876543210Sym1 :: GHC.Num.Natural.Natural - -> (~>) (Maybe a) ((~>) GHC.Types.Symbol GHC.Types.Symbol) + type ShowsPrec_0123456789876543210Sym1 :: forall a. GHC.Num.Natural.Natural + -> (~>) (Maybe a) ((~>) GHC.Types.Symbol GHC.Types.Symbol) data ShowsPrec_0123456789876543210Sym1 (a0123456789876543210 :: GHC.Num.Natural.Natural) :: (~>) (Maybe a) ((~>) GHC.Types.Symbol GHC.Types.Symbol) where ShowsPrec_0123456789876543210Sym1KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -75,8 +78,9 @@ Singletons/Maybe.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym1KindInference ()) - type ShowsPrec_0123456789876543210Sym2 :: GHC.Num.Natural.Natural - -> Maybe a -> (~>) GHC.Types.Symbol GHC.Types.Symbol + type ShowsPrec_0123456789876543210Sym2 :: forall a. GHC.Num.Natural.Natural + -> Maybe a + -> (~>) GHC.Types.Symbol GHC.Types.Symbol data ShowsPrec_0123456789876543210Sym2 (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: Maybe a) :: (~>) GHC.Types.Symbol GHC.Types.Symbol where ShowsPrec_0123456789876543210Sym2KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 arg) => @@ -85,8 +89,9 @@ Singletons/Maybe.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym2KindInference ()) - type ShowsPrec_0123456789876543210Sym3 :: GHC.Num.Natural.Natural - -> Maybe a -> GHC.Types.Symbol -> GHC.Types.Symbol + type ShowsPrec_0123456789876543210Sym3 :: forall a. GHC.Num.Natural.Natural + -> Maybe a + -> GHC.Types.Symbol -> GHC.Types.Symbol type family ShowsPrec_0123456789876543210Sym3 @a (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: Maybe a) (a0123456789876543210 :: GHC.Types.Symbol) :: GHC.Types.Symbol where ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 a0123456789876543210 = ShowsPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210 instance PShow (Maybe a) where @@ -104,11 +109,6 @@ Singletons/Maybe.hs:(0,0)-(0,0): Splicing declarations toSing (Just (b :: Demote a)) = case toSing b :: SomeSing a of SomeSing c -> SomeSing (SJust c) instance SEq a => SEq (Maybe a) where - (%==) :: - forall (t1 :: Maybe a) (t2 :: Maybe a). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun (Maybe a) ((~>) (Maybe a) Bool) - -> Type) t1) t2) (%==) SNothing SNothing = STrue (%==) SNothing (SJust _) = SFalse (%==) (SJust _) SNothing = SFalse @@ -119,14 +119,6 @@ Singletons/Maybe.hs:(0,0)-(0,0): Splicing declarations (applySing (singFun2 @(==@#@$) (%==)) sA_0123456789876543210) sB_0123456789876543210 instance SShow a => SShow (Maybe a) where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: Maybe a) - (t3 :: GHC.Types.Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) (Maybe a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SNothing diff --git a/singletons-base/tests/compile-and-dump/Singletons/Nat.golden b/singletons-base/tests/compile-and-dump/Singletons/Nat.golden index 6380764d..8d6abc58 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/Nat.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/Nat.golden @@ -211,11 +211,6 @@ Singletons/Nat.hs:(0,0)-(0,0): Splicing declarations toSing (Succ (b :: Demote Nat)) = case toSing b :: SomeSing Nat of SomeSing c -> SomeSing (SSucc c) instance SEq Nat => SEq Nat where - (%==) :: - forall (t1 :: Nat) (t2 :: Nat). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun Nat ((~>) Nat Bool) - -> Type) t1) t2) (%==) SZero SZero = STrue (%==) SZero (SSucc _) = SFalse (%==) (SSucc _) SZero = SFalse @@ -226,14 +221,6 @@ Singletons/Nat.hs:(0,0)-(0,0): Splicing declarations (applySing (singFun2 @(==@#@$) (%==)) sA_0123456789876543210) sB_0123456789876543210 instance SShow Nat => SShow Nat where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: Nat) - (t3 :: GHC.Types.Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) Nat ((~>) GHC.Types.Symbol GHC.Types.Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SZero @@ -265,11 +252,6 @@ Singletons/Nat.hs:(0,0)-(0,0): Splicing declarations sArg_0123456789876543210))) sA_0123456789876543210 instance SOrd Nat => SOrd Nat where - sCompare :: - forall (t1 :: Nat) (t2 :: Nat). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun Nat ((~>) Nat Ordering) - -> Type) t1) t2) sCompare SZero SZero = applySing (applySing diff --git a/singletons-base/tests/compile-and-dump/Singletons/OrdDeriving.golden b/singletons-base/tests/compile-and-dump/Singletons/OrdDeriving.golden index 2abd0838..516bfb3e 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/OrdDeriving.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/OrdDeriving.golden @@ -335,46 +335,49 @@ Singletons/OrdDeriving.hs:(0,0)-(0,0): Splicing declarations Compare_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Compare_0123456789876543210 a0123456789876543210 a0123456789876543210 instance POrd Nat where type Compare a a = Apply (Apply Compare_0123456789876543210Sym0 a) a - type TFHelper_0123456789876543210 :: Foo a b c d - -> Foo a b c d -> Bool + type TFHelper_0123456789876543210 :: forall a b c d. Foo a b c d + -> Foo a b c d -> Bool type family TFHelper_0123456789876543210 @a @b @c @d (a :: Foo a b c d) (a :: Foo a b c d) :: Bool where - TFHelper_0123456789876543210 (A a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (A b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) - TFHelper_0123456789876543210 (A _ _ _ _) (B _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (A _ _ _ _) (C _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (A _ _ _ _) (D _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (A _ _ _ _) (E _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (A _ _ _ _) (F _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (B _ _ _ _) (A _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (B a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (B b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) - TFHelper_0123456789876543210 (B _ _ _ _) (C _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (B _ _ _ _) (D _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (B _ _ _ _) (E _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (B _ _ _ _) (F _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (C _ _ _ _) (A _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (C _ _ _ _) (B _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (C a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (C b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) - TFHelper_0123456789876543210 (C _ _ _ _) (D _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (C _ _ _ _) (E _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (C _ _ _ _) (F _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (D _ _ _ _) (A _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (D _ _ _ _) (B _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (D _ _ _ _) (C _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (D a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (D b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) - TFHelper_0123456789876543210 (D _ _ _ _) (E _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (D _ _ _ _) (F _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (E _ _ _ _) (A _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (E _ _ _ _) (B _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (E _ _ _ _) (C _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (E _ _ _ _) (D _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (E a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (E b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) - TFHelper_0123456789876543210 (E _ _ _ _) (F _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (F _ _ _ _) (A _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (F _ _ _ _) (B _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (F _ _ _ _) (C _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (F _ _ _ _) (D _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (F _ _ _ _) (E _ _ _ _) = FalseSym0 - TFHelper_0123456789876543210 (F a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (F b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) - type TFHelper_0123456789876543210Sym0 :: (~>) (Foo a b c d) ((~>) (Foo a b c d) Bool) + TFHelper_0123456789876543210 @a @b @c @d (A a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (A b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) + TFHelper_0123456789876543210 @a @b @c @d (A _ _ _ _ :: Foo a b c d) (B _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (A _ _ _ _ :: Foo a b c d) (C _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (A _ _ _ _ :: Foo a b c d) (D _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (A _ _ _ _ :: Foo a b c d) (E _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (A _ _ _ _ :: Foo a b c d) (F _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (B _ _ _ _ :: Foo a b c d) (A _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (B a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (B b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) + TFHelper_0123456789876543210 @a @b @c @d (B _ _ _ _ :: Foo a b c d) (C _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (B _ _ _ _ :: Foo a b c d) (D _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (B _ _ _ _ :: Foo a b c d) (E _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (B _ _ _ _ :: Foo a b c d) (F _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (C _ _ _ _ :: Foo a b c d) (A _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (C _ _ _ _ :: Foo a b c d) (B _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (C a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (C b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) + TFHelper_0123456789876543210 @a @b @c @d (C _ _ _ _ :: Foo a b c d) (D _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (C _ _ _ _ :: Foo a b c d) (E _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (C _ _ _ _ :: Foo a b c d) (F _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (D _ _ _ _ :: Foo a b c d) (A _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (D _ _ _ _ :: Foo a b c d) (B _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (D _ _ _ _ :: Foo a b c d) (C _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (D a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (D b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) + TFHelper_0123456789876543210 @a @b @c @d (D _ _ _ _ :: Foo a b c d) (E _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (D _ _ _ _ :: Foo a b c d) (F _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (E _ _ _ _ :: Foo a b c d) (A _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (E _ _ _ _ :: Foo a b c d) (B _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (E _ _ _ _ :: Foo a b c d) (C _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (E _ _ _ _ :: Foo a b c d) (D _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (E a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (E b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) + TFHelper_0123456789876543210 @a @b @c @d (E _ _ _ _ :: Foo a b c d) (F _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (F _ _ _ _ :: Foo a b c d) (A _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (F _ _ _ _ :: Foo a b c d) (B _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (F _ _ _ _ :: Foo a b c d) (C _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (F _ _ _ _ :: Foo a b c d) (D _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (F _ _ _ _ :: Foo a b c d) (E _ _ _ _ :: Foo a b c d) = FalseSym0 + TFHelper_0123456789876543210 @a @b @c @d (F a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (F b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210))) + type TFHelper_0123456789876543210Sym0 :: forall a + b + c + d. (~>) (Foo a b c d) ((~>) (Foo a b c d) Bool) data TFHelper_0123456789876543210Sym0 :: (~>) (Foo a b c d) ((~>) (Foo a b c d) Bool) where TFHelper_0123456789876543210Sym0KindInference :: SameKind (Apply TFHelper_0123456789876543210Sym0 arg) (TFHelper_0123456789876543210Sym1 arg) => @@ -383,8 +386,10 @@ Singletons/OrdDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings TFHelper_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym0KindInference ()) - type TFHelper_0123456789876543210Sym1 :: Foo a b c d - -> (~>) (Foo a b c d) Bool + type TFHelper_0123456789876543210Sym1 :: forall a + b + c + d. Foo a b c d -> (~>) (Foo a b c d) Bool data TFHelper_0123456789876543210Sym1 (a0123456789876543210 :: Foo a b c d) :: (~>) (Foo a b c d) Bool where TFHelper_0123456789876543210Sym1KindInference :: SameKind (Apply (TFHelper_0123456789876543210Sym1 a0123456789876543210) arg) (TFHelper_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -393,52 +398,57 @@ Singletons/OrdDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (TFHelper_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym1KindInference ()) - type TFHelper_0123456789876543210Sym2 :: Foo a b c d - -> Foo a b c d -> Bool + type TFHelper_0123456789876543210Sym2 :: forall a + b + c + d. Foo a b c d -> Foo a b c d -> Bool type family TFHelper_0123456789876543210Sym2 @a @b @c @d (a0123456789876543210 :: Foo a b c d) (a0123456789876543210 :: Foo a b c d) :: Bool where TFHelper_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = TFHelper_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PEq (Foo a b c d) where type (==) a a = Apply (Apply TFHelper_0123456789876543210Sym0 a) a - type Compare_0123456789876543210 :: Foo a b c d - -> Foo a b c d -> Ordering + type Compare_0123456789876543210 :: forall a b c d. Foo a b c d + -> Foo a b c d -> Ordering type family Compare_0123456789876543210 @a @b @c @d (a :: Foo a b c d) (a :: Foo a b c d) :: Ordering where - Compare_0123456789876543210 (A a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (A b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) - Compare_0123456789876543210 (B a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (B b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) - Compare_0123456789876543210 (C a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (C b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) - Compare_0123456789876543210 (D a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (D b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) - Compare_0123456789876543210 (E a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (E b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) - Compare_0123456789876543210 (F a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210) (F b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) - Compare_0123456789876543210 (A _ _ _ _) (B _ _ _ _) = LTSym0 - Compare_0123456789876543210 (A _ _ _ _) (C _ _ _ _) = LTSym0 - Compare_0123456789876543210 (A _ _ _ _) (D _ _ _ _) = LTSym0 - Compare_0123456789876543210 (A _ _ _ _) (E _ _ _ _) = LTSym0 - Compare_0123456789876543210 (A _ _ _ _) (F _ _ _ _) = LTSym0 - Compare_0123456789876543210 (B _ _ _ _) (A _ _ _ _) = GTSym0 - Compare_0123456789876543210 (B _ _ _ _) (C _ _ _ _) = LTSym0 - Compare_0123456789876543210 (B _ _ _ _) (D _ _ _ _) = LTSym0 - Compare_0123456789876543210 (B _ _ _ _) (E _ _ _ _) = LTSym0 - Compare_0123456789876543210 (B _ _ _ _) (F _ _ _ _) = LTSym0 - Compare_0123456789876543210 (C _ _ _ _) (A _ _ _ _) = GTSym0 - Compare_0123456789876543210 (C _ _ _ _) (B _ _ _ _) = GTSym0 - Compare_0123456789876543210 (C _ _ _ _) (D _ _ _ _) = LTSym0 - Compare_0123456789876543210 (C _ _ _ _) (E _ _ _ _) = LTSym0 - Compare_0123456789876543210 (C _ _ _ _) (F _ _ _ _) = LTSym0 - Compare_0123456789876543210 (D _ _ _ _) (A _ _ _ _) = GTSym0 - Compare_0123456789876543210 (D _ _ _ _) (B _ _ _ _) = GTSym0 - Compare_0123456789876543210 (D _ _ _ _) (C _ _ _ _) = GTSym0 - Compare_0123456789876543210 (D _ _ _ _) (E _ _ _ _) = LTSym0 - Compare_0123456789876543210 (D _ _ _ _) (F _ _ _ _) = LTSym0 - Compare_0123456789876543210 (E _ _ _ _) (A _ _ _ _) = GTSym0 - Compare_0123456789876543210 (E _ _ _ _) (B _ _ _ _) = GTSym0 - Compare_0123456789876543210 (E _ _ _ _) (C _ _ _ _) = GTSym0 - Compare_0123456789876543210 (E _ _ _ _) (D _ _ _ _) = GTSym0 - Compare_0123456789876543210 (E _ _ _ _) (F _ _ _ _) = LTSym0 - Compare_0123456789876543210 (F _ _ _ _) (A _ _ _ _) = GTSym0 - Compare_0123456789876543210 (F _ _ _ _) (B _ _ _ _) = GTSym0 - Compare_0123456789876543210 (F _ _ _ _) (C _ _ _ _) = GTSym0 - Compare_0123456789876543210 (F _ _ _ _) (D _ _ _ _) = GTSym0 - Compare_0123456789876543210 (F _ _ _ _) (E _ _ _ _) = GTSym0 - type Compare_0123456789876543210Sym0 :: (~>) (Foo a b c d) ((~>) (Foo a b c d) Ordering) + Compare_0123456789876543210 @a @b @c @d (A a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (A b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) + Compare_0123456789876543210 @a @b @c @d (B a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (B b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) + Compare_0123456789876543210 @a @b @c @d (C a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (C b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) + Compare_0123456789876543210 @a @b @c @d (D a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (D b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) + Compare_0123456789876543210 @a @b @c @d (E a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (E b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) + Compare_0123456789876543210 @a @b @c @d (F a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 a_0123456789876543210 :: Foo a b c d) (F b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 b_0123456789876543210 :: Foo a b c d) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)))) + Compare_0123456789876543210 @a @b @c @d (A _ _ _ _ :: Foo a b c d) (B _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (A _ _ _ _ :: Foo a b c d) (C _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (A _ _ _ _ :: Foo a b c d) (D _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (A _ _ _ _ :: Foo a b c d) (E _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (A _ _ _ _ :: Foo a b c d) (F _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (B _ _ _ _ :: Foo a b c d) (A _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (B _ _ _ _ :: Foo a b c d) (C _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (B _ _ _ _ :: Foo a b c d) (D _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (B _ _ _ _ :: Foo a b c d) (E _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (B _ _ _ _ :: Foo a b c d) (F _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (C _ _ _ _ :: Foo a b c d) (A _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (C _ _ _ _ :: Foo a b c d) (B _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (C _ _ _ _ :: Foo a b c d) (D _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (C _ _ _ _ :: Foo a b c d) (E _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (C _ _ _ _ :: Foo a b c d) (F _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (D _ _ _ _ :: Foo a b c d) (A _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (D _ _ _ _ :: Foo a b c d) (B _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (D _ _ _ _ :: Foo a b c d) (C _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (D _ _ _ _ :: Foo a b c d) (E _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (D _ _ _ _ :: Foo a b c d) (F _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (E _ _ _ _ :: Foo a b c d) (A _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (E _ _ _ _ :: Foo a b c d) (B _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (E _ _ _ _ :: Foo a b c d) (C _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (E _ _ _ _ :: Foo a b c d) (D _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (E _ _ _ _ :: Foo a b c d) (F _ _ _ _ :: Foo a b c d) = LTSym0 + Compare_0123456789876543210 @a @b @c @d (F _ _ _ _ :: Foo a b c d) (A _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (F _ _ _ _ :: Foo a b c d) (B _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (F _ _ _ _ :: Foo a b c d) (C _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (F _ _ _ _ :: Foo a b c d) (D _ _ _ _ :: Foo a b c d) = GTSym0 + Compare_0123456789876543210 @a @b @c @d (F _ _ _ _ :: Foo a b c d) (E _ _ _ _ :: Foo a b c d) = GTSym0 + type Compare_0123456789876543210Sym0 :: forall a + b + c + d. (~>) (Foo a b c d) ((~>) (Foo a b c d) Ordering) data Compare_0123456789876543210Sym0 :: (~>) (Foo a b c d) ((~>) (Foo a b c d) Ordering) where Compare_0123456789876543210Sym0KindInference :: SameKind (Apply Compare_0123456789876543210Sym0 arg) (Compare_0123456789876543210Sym1 arg) => @@ -447,8 +457,8 @@ Singletons/OrdDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Compare_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Compare_0123456789876543210Sym0KindInference ()) - type Compare_0123456789876543210Sym1 :: Foo a b c d - -> (~>) (Foo a b c d) Ordering + type Compare_0123456789876543210Sym1 :: forall a b c d. Foo a b c d + -> (~>) (Foo a b c d) Ordering data Compare_0123456789876543210Sym1 (a0123456789876543210 :: Foo a b c d) :: (~>) (Foo a b c d) Ordering where Compare_0123456789876543210Sym1KindInference :: SameKind (Apply (Compare_0123456789876543210Sym1 a0123456789876543210) arg) (Compare_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -457,8 +467,8 @@ Singletons/OrdDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Compare_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Compare_0123456789876543210Sym1KindInference ()) - type Compare_0123456789876543210Sym2 :: Foo a b c d - -> Foo a b c d -> Ordering + type Compare_0123456789876543210Sym2 :: forall a b c d. Foo a b c d + -> Foo a b c d -> Ordering type family Compare_0123456789876543210Sym2 @a @b @c @d (a0123456789876543210 :: Foo a b c d) (a0123456789876543210 :: Foo a b c d) :: Ordering where Compare_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Compare_0123456789876543210 a0123456789876543210 a0123456789876543210 instance POrd (Foo a b c d) where @@ -584,11 +594,6 @@ Singletons/OrdDeriving.hs:(0,0)-(0,0): Splicing declarations (,,,) (SomeSing c) (SomeSing c) (SomeSing c) (SomeSing c) -> SomeSing (SF c c c c) instance SEq Nat => SEq Nat where - (%==) :: - forall (t1 :: Nat) (t2 :: Nat). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun Nat ((~>) Nat Bool) - -> Type) t1) t2) (%==) SZero SZero = STrue (%==) SZero (SSucc _) = SFalse (%==) (SSucc _) SZero = SFalse @@ -599,11 +604,6 @@ Singletons/OrdDeriving.hs:(0,0)-(0,0): Splicing declarations (applySing (singFun2 @(==@#@$) (%==)) sA_0123456789876543210) sB_0123456789876543210 instance SOrd Nat => SOrd Nat where - sCompare :: - forall (t1 :: Nat) (t2 :: Nat). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun Nat ((~>) Nat Ordering) - -> Type) t1) t2) sCompare SZero SZero = applySing (applySing @@ -627,11 +627,6 @@ Singletons/OrdDeriving.hs:(0,0)-(0,0): Splicing declarations sCompare SZero (SSucc _) = SLT sCompare (SSucc _) SZero = SGT instance (SEq a, SEq b, SEq c, SEq d) => SEq (Foo a b c d) where - (%==) :: - forall (t1 :: Foo a b c d) (t2 :: Foo a b c d). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun (Foo a b c d) ((~>) (Foo a b c d) Bool) - -> Type) t1) t2) (%==) (SA (sA_0123456789876543210 :: Sing a_0123456789876543210) (sA_0123456789876543210 :: Sing a_0123456789876543210) @@ -844,11 +839,6 @@ Singletons/OrdDeriving.hs:(0,0)-(0,0): Splicing declarations sB_0123456789876543210))) instance (SOrd a, SOrd b, SOrd c, SOrd d) => SOrd (Foo a b c d) where - sCompare :: - forall (t1 :: Foo a b c d) (t2 :: Foo a b c d). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun (Foo a b c d) ((~>) (Foo a b c d) Ordering) - -> Type) t1) t2) sCompare (SA (sA_0123456789876543210 :: Sing a_0123456789876543210) (sA_0123456789876543210 :: Sing a_0123456789876543210) diff --git a/singletons-base/tests/compile-and-dump/Singletons/PatternMatching.golden b/singletons-base/tests/compile-and-dump/Singletons/PatternMatching.golden index 49bd105e..2d54150a 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/PatternMatching.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/PatternMatching.golden @@ -51,11 +51,13 @@ Singletons/PatternMatching.hs:(0,0)-(0,0): Splicing declarations Complex = Apply (Apply PairSym0 (Apply (Apply PairSym0 (Apply JustSym0 ZeroSym0)) ZeroSym0)) FalseSym0 type family Pr where Pr = Apply (Apply PairSym0 (Apply SuccSym0 ZeroSym0)) (Apply (Apply (:@#@$) ZeroSym0) NilSym0) - type ShowsPrec_0123456789876543210 :: GHC.Num.Natural.Natural - -> Pair a b -> Symbol -> Symbol + type ShowsPrec_0123456789876543210 :: forall a + b. GHC.Num.Natural.Natural + -> Pair a b -> Symbol -> Symbol type family ShowsPrec_0123456789876543210 @a @b (a :: GHC.Num.Natural.Natural) (a :: Pair a b) (a :: Symbol) :: Symbol where - ShowsPrec_0123456789876543210 p_0123456789876543210 (Pair arg_0123456789876543210 arg_0123456789876543210) a_0123456789876543210 = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "Pair ")) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210)) (Apply (Apply (.@#@$) ShowSpaceSym0) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))))) a_0123456789876543210 - type ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (Pair a b) ((~>) Symbol Symbol)) + ShowsPrec_0123456789876543210 @a @b (p_0123456789876543210 :: GHC.Num.Natural.Natural) (Pair arg_0123456789876543210 arg_0123456789876543210 :: Pair a b) (a_0123456789876543210 :: Symbol) = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "Pair ")) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210)) (Apply (Apply (.@#@$) ShowSpaceSym0) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))))) a_0123456789876543210 + type ShowsPrec_0123456789876543210Sym0 :: forall a + b. (~>) GHC.Num.Natural.Natural ((~>) (Pair a b) ((~>) Symbol Symbol)) data ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (Pair a b) ((~>) Symbol Symbol)) where ShowsPrec_0123456789876543210Sym0KindInference :: SameKind (Apply ShowsPrec_0123456789876543210Sym0 arg) (ShowsPrec_0123456789876543210Sym1 arg) => @@ -64,8 +66,9 @@ Singletons/PatternMatching.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings ShowsPrec_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym0KindInference ()) - type ShowsPrec_0123456789876543210Sym1 :: GHC.Num.Natural.Natural - -> (~>) (Pair a b) ((~>) Symbol Symbol) + type ShowsPrec_0123456789876543210Sym1 :: forall a + b. GHC.Num.Natural.Natural + -> (~>) (Pair a b) ((~>) Symbol Symbol) data ShowsPrec_0123456789876543210Sym1 (a0123456789876543210 :: GHC.Num.Natural.Natural) :: (~>) (Pair a b) ((~>) Symbol Symbol) where ShowsPrec_0123456789876543210Sym1KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -74,8 +77,9 @@ Singletons/PatternMatching.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym1KindInference ()) - type ShowsPrec_0123456789876543210Sym2 :: GHC.Num.Natural.Natural - -> Pair a b -> (~>) Symbol Symbol + type ShowsPrec_0123456789876543210Sym2 :: forall a + b. GHC.Num.Natural.Natural + -> Pair a b -> (~>) Symbol Symbol data ShowsPrec_0123456789876543210Sym2 (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: Pair a b) :: (~>) Symbol Symbol where ShowsPrec_0123456789876543210Sym2KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 arg) => @@ -84,8 +88,9 @@ Singletons/PatternMatching.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym2KindInference ()) - type ShowsPrec_0123456789876543210Sym3 :: GHC.Num.Natural.Natural - -> Pair a b -> Symbol -> Symbol + type ShowsPrec_0123456789876543210Sym3 :: forall a + b. GHC.Num.Natural.Natural + -> Pair a b -> Symbol -> Symbol type family ShowsPrec_0123456789876543210Sym3 @a @b (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: Pair a b) (a0123456789876543210 :: Symbol) :: Symbol where ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 a0123456789876543210 = ShowsPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210 instance PShow (Pair a b) where @@ -142,14 +147,6 @@ Singletons/PatternMatching.hs:(0,0)-(0,0): Splicing declarations = case (,) (toSing b :: SomeSing a) (toSing b :: SomeSing b) of (,) (SomeSing c) (SomeSing c) -> SomeSing (SPair c c) instance (SShow a, SShow b) => SShow (Pair a b) where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: Pair a b) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) (Pair a b) ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec (sP_0123456789876543210 :: Sing p_0123456789876543210) (SPair (sArg_0123456789876543210 :: Sing arg_0123456789876543210) diff --git a/singletons-base/tests/compile-and-dump/Singletons/ShowDeriving.golden b/singletons-base/tests/compile-and-dump/Singletons/ShowDeriving.golden index 8c855cb8..50defbca 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/ShowDeriving.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/ShowDeriving.golden @@ -198,14 +198,14 @@ Singletons/ShowDeriving.hs:(0,0)-(0,0): Splicing declarations ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 a0123456789876543210 = ShowsPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210 instance PShow Foo1 where type ShowsPrec a a a = Apply (Apply (Apply ShowsPrec_0123456789876543210Sym0 a) a) a - type ShowsPrec_0123456789876543210 :: GHC.Num.Natural.Natural - -> Foo2 a -> Symbol -> Symbol + type ShowsPrec_0123456789876543210 :: forall a. GHC.Num.Natural.Natural + -> Foo2 a -> Symbol -> Symbol type family ShowsPrec_0123456789876543210 @a (a :: GHC.Num.Natural.Natural) (a :: Foo2 a) (a :: Symbol) :: Symbol where - ShowsPrec_0123456789876543210 p_0123456789876543210 (MkFoo2a arg_0123456789876543210 arg_0123456789876543210) a_0123456789876543210 = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "MkFoo2a ")) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210)) (Apply (Apply (.@#@$) ShowSpaceSym0) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))))) a_0123456789876543210 - ShowsPrec_0123456789876543210 p_0123456789876543210 (MkFoo2b argL_0123456789876543210 argR_0123456789876543210) a_0123456789876543210 = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 5))) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 6)) argL_0123456789876543210)) (Apply (Apply (.@#@$) (Apply ShowStringSym0 " `MkFoo2b` ")) (Apply (Apply ShowsPrecSym0 (FromInteger 6)) argR_0123456789876543210)))) a_0123456789876543210 - ShowsPrec_0123456789876543210 p_0123456789876543210 ((:*:) arg_0123456789876543210 arg_0123456789876543210) a_0123456789876543210 = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "(:*:) ")) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210)) (Apply (Apply (.@#@$) ShowSpaceSym0) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))))) a_0123456789876543210 - ShowsPrec_0123456789876543210 p_0123456789876543210 ((:&:) argL_0123456789876543210 argR_0123456789876543210) a_0123456789876543210 = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 5))) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 6)) argL_0123456789876543210)) (Apply (Apply (.@#@$) (Apply ShowStringSym0 " :&: ")) (Apply (Apply ShowsPrecSym0 (FromInteger 6)) argR_0123456789876543210)))) a_0123456789876543210 - type ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (Foo2 a) ((~>) Symbol Symbol)) + ShowsPrec_0123456789876543210 @a (p_0123456789876543210 :: GHC.Num.Natural.Natural) (MkFoo2a arg_0123456789876543210 arg_0123456789876543210 :: Foo2 a) (a_0123456789876543210 :: Symbol) = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "MkFoo2a ")) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210)) (Apply (Apply (.@#@$) ShowSpaceSym0) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))))) a_0123456789876543210 + ShowsPrec_0123456789876543210 @a (p_0123456789876543210 :: GHC.Num.Natural.Natural) (MkFoo2b argL_0123456789876543210 argR_0123456789876543210 :: Foo2 a) (a_0123456789876543210 :: Symbol) = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 5))) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 6)) argL_0123456789876543210)) (Apply (Apply (.@#@$) (Apply ShowStringSym0 " `MkFoo2b` ")) (Apply (Apply ShowsPrecSym0 (FromInteger 6)) argR_0123456789876543210)))) a_0123456789876543210 + ShowsPrec_0123456789876543210 @a (p_0123456789876543210 :: GHC.Num.Natural.Natural) ((:*:) arg_0123456789876543210 arg_0123456789876543210 :: Foo2 a) (a_0123456789876543210 :: Symbol) = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "(:*:) ")) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210)) (Apply (Apply (.@#@$) ShowSpaceSym0) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))))) a_0123456789876543210 + ShowsPrec_0123456789876543210 @a (p_0123456789876543210 :: GHC.Num.Natural.Natural) ((:&:) argL_0123456789876543210 argR_0123456789876543210 :: Foo2 a) (a_0123456789876543210 :: Symbol) = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 5))) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 6)) argL_0123456789876543210)) (Apply (Apply (.@#@$) (Apply ShowStringSym0 " :&: ")) (Apply (Apply ShowsPrecSym0 (FromInteger 6)) argR_0123456789876543210)))) a_0123456789876543210 + type ShowsPrec_0123456789876543210Sym0 :: forall a. (~>) GHC.Num.Natural.Natural ((~>) (Foo2 a) ((~>) Symbol Symbol)) data ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (Foo2 a) ((~>) Symbol Symbol)) where ShowsPrec_0123456789876543210Sym0KindInference :: SameKind (Apply ShowsPrec_0123456789876543210Sym0 arg) (ShowsPrec_0123456789876543210Sym1 arg) => @@ -214,8 +214,8 @@ Singletons/ShowDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings ShowsPrec_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym0KindInference ()) - type ShowsPrec_0123456789876543210Sym1 :: GHC.Num.Natural.Natural - -> (~>) (Foo2 a) ((~>) Symbol Symbol) + type ShowsPrec_0123456789876543210Sym1 :: forall a. GHC.Num.Natural.Natural + -> (~>) (Foo2 a) ((~>) Symbol Symbol) data ShowsPrec_0123456789876543210Sym1 (a0123456789876543210 :: GHC.Num.Natural.Natural) :: (~>) (Foo2 a) ((~>) Symbol Symbol) where ShowsPrec_0123456789876543210Sym1KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -224,8 +224,8 @@ Singletons/ShowDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym1KindInference ()) - type ShowsPrec_0123456789876543210Sym2 :: GHC.Num.Natural.Natural - -> Foo2 a -> (~>) Symbol Symbol + type ShowsPrec_0123456789876543210Sym2 :: forall a. GHC.Num.Natural.Natural + -> Foo2 a -> (~>) Symbol Symbol data ShowsPrec_0123456789876543210Sym2 (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: Foo2 a) :: (~>) Symbol Symbol where ShowsPrec_0123456789876543210Sym2KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 arg) => @@ -234,8 +234,8 @@ Singletons/ShowDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym2KindInference ()) - type ShowsPrec_0123456789876543210Sym3 :: GHC.Num.Natural.Natural - -> Foo2 a -> Symbol -> Symbol + type ShowsPrec_0123456789876543210Sym3 :: forall a. GHC.Num.Natural.Natural + -> Foo2 a -> Symbol -> Symbol type family ShowsPrec_0123456789876543210Sym3 @a (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: Foo2 a) (a0123456789876543210 :: Symbol) :: Symbol where ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 a0123456789876543210 = ShowsPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210 instance PShow (Foo2 a) where @@ -343,14 +343,6 @@ Singletons/ShowDeriving.hs:(0,0)-(0,0): Splicing declarations of (,) (SomeSing c) (SomeSing c) -> SomeSing (SMkFoo3 c c) instance SShow Foo1 where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: Foo1) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) Foo1 ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SMkFoo1 @@ -360,14 +352,6 @@ Singletons/ShowDeriving.hs:(0,0)-(0,0): Splicing declarations (singFun2 @ShowStringSym0 sShowString) (sing :: Sing "MkFoo1")) sA_0123456789876543210 instance SShow a => SShow (Foo2 a) where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: Foo2 a) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) (Foo2 a) ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec (sP_0123456789876543210 :: Sing p_0123456789876543210) (SMkFoo2a (sArg_0123456789876543210 :: Sing arg_0123456789876543210) @@ -500,14 +484,6 @@ Singletons/ShowDeriving.hs:(0,0)-(0,0): Splicing declarations sArgR_0123456789876543210)))) sA_0123456789876543210 instance SShow Bool => SShow Foo3 where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: Foo3) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) Foo3 ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec (sP_0123456789876543210 :: Sing p_0123456789876543210) (SMkFoo3 (sArg_0123456789876543210 :: Sing arg_0123456789876543210) diff --git a/singletons-base/tests/compile-and-dump/Singletons/StandaloneDeriving.golden b/singletons-base/tests/compile-and-dump/Singletons/StandaloneDeriving.golden index c06f66b2..36a2a8e1 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/StandaloneDeriving.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/StandaloneDeriving.golden @@ -53,10 +53,11 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations type S2Sym0 :: S type family S2Sym0 :: S where S2Sym0 = S2 - type TFHelper_0123456789876543210 :: T a () -> T a () -> Bool + type TFHelper_0123456789876543210 :: forall a. T a () + -> T a () -> Bool type family TFHelper_0123456789876543210 @a (a :: T a ()) (a :: T a ()) :: Bool where - TFHelper_0123456789876543210 ((:*:) a_0123456789876543210 a_0123456789876543210) ((:*:) b_0123456789876543210 b_0123456789876543210) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210) - type TFHelper_0123456789876543210Sym0 :: (~>) (T a ()) ((~>) (T a ()) Bool) + TFHelper_0123456789876543210 @a ((:*:) a_0123456789876543210 a_0123456789876543210 :: T a ()) ((:*:) b_0123456789876543210 b_0123456789876543210 :: T a ()) = Apply (Apply (&&@#@$) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210) + type TFHelper_0123456789876543210Sym0 :: forall a. (~>) (T a ()) ((~>) (T a ()) Bool) data TFHelper_0123456789876543210Sym0 :: (~>) (T a ()) ((~>) (T a ()) Bool) where TFHelper_0123456789876543210Sym0KindInference :: SameKind (Apply TFHelper_0123456789876543210Sym0 arg) (TFHelper_0123456789876543210Sym1 arg) => @@ -65,8 +66,8 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings TFHelper_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym0KindInference ()) - type TFHelper_0123456789876543210Sym1 :: T a () - -> (~>) (T a ()) Bool + type TFHelper_0123456789876543210Sym1 :: forall a. T a () + -> (~>) (T a ()) Bool data TFHelper_0123456789876543210Sym1 (a0123456789876543210 :: T a ()) :: (~>) (T a ()) Bool where TFHelper_0123456789876543210Sym1KindInference :: SameKind (Apply (TFHelper_0123456789876543210Sym1 a0123456789876543210) arg) (TFHelper_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -75,15 +76,17 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (TFHelper_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym1KindInference ()) - type TFHelper_0123456789876543210Sym2 :: T a () -> T a () -> Bool + type TFHelper_0123456789876543210Sym2 :: forall a. T a () + -> T a () -> Bool type family TFHelper_0123456789876543210Sym2 @a (a0123456789876543210 :: T a ()) (a0123456789876543210 :: T a ()) :: Bool where TFHelper_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = TFHelper_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PEq (T a ()) where type (==) a a = Apply (Apply TFHelper_0123456789876543210Sym0 a) a - type Compare_0123456789876543210 :: T a () -> T a () -> Ordering + type Compare_0123456789876543210 :: forall a. T a () + -> T a () -> Ordering type family Compare_0123456789876543210 @a (a :: T a ()) (a :: T a ()) :: Ordering where - Compare_0123456789876543210 ((:*:) a_0123456789876543210 a_0123456789876543210) ((:*:) b_0123456789876543210 b_0123456789876543210) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)) - type Compare_0123456789876543210Sym0 :: (~>) (T a ()) ((~>) (T a ()) Ordering) + Compare_0123456789876543210 @a ((:*:) a_0123456789876543210 a_0123456789876543210 :: T a ()) ((:*:) b_0123456789876543210 b_0123456789876543210 :: T a ()) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0)) + type Compare_0123456789876543210Sym0 :: forall a. (~>) (T a ()) ((~>) (T a ()) Ordering) data Compare_0123456789876543210Sym0 :: (~>) (T a ()) ((~>) (T a ()) Ordering) where Compare_0123456789876543210Sym0KindInference :: SameKind (Apply Compare_0123456789876543210Sym0 arg) (Compare_0123456789876543210Sym1 arg) => @@ -92,8 +95,8 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Compare_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Compare_0123456789876543210Sym0KindInference ()) - type Compare_0123456789876543210Sym1 :: T a () - -> (~>) (T a ()) Ordering + type Compare_0123456789876543210Sym1 :: forall a. T a () + -> (~>) (T a ()) Ordering data Compare_0123456789876543210Sym1 (a0123456789876543210 :: T a ()) :: (~>) (T a ()) Ordering where Compare_0123456789876543210Sym1KindInference :: SameKind (Apply (Compare_0123456789876543210Sym1 a0123456789876543210) arg) (Compare_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -102,17 +105,17 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Compare_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Compare_0123456789876543210Sym1KindInference ()) - type Compare_0123456789876543210Sym2 :: T a () - -> T a () -> Ordering + type Compare_0123456789876543210Sym2 :: forall a. T a () + -> T a () -> Ordering type family Compare_0123456789876543210Sym2 @a (a0123456789876543210 :: T a ()) (a0123456789876543210 :: T a ()) :: Ordering where Compare_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Compare_0123456789876543210 a0123456789876543210 a0123456789876543210 instance POrd (T a ()) where type Compare a a = Apply (Apply Compare_0123456789876543210Sym0 a) a - type ShowsPrec_0123456789876543210 :: GHC.Num.Natural.Natural - -> T a () -> Symbol -> Symbol + type ShowsPrec_0123456789876543210 :: forall a. GHC.Num.Natural.Natural + -> T a () -> Symbol -> Symbol type family ShowsPrec_0123456789876543210 @a (a :: GHC.Num.Natural.Natural) (a :: T a ()) (a :: Symbol) :: Symbol where - ShowsPrec_0123456789876543210 p_0123456789876543210 ((:*:) argL_0123456789876543210 argR_0123456789876543210) a_0123456789876543210 = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 6))) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 7)) argL_0123456789876543210)) (Apply (Apply (.@#@$) (Apply ShowStringSym0 " :*: ")) (Apply (Apply ShowsPrecSym0 (FromInteger 7)) argR_0123456789876543210)))) a_0123456789876543210 - type ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (T a ()) ((~>) Symbol Symbol)) + ShowsPrec_0123456789876543210 @a (p_0123456789876543210 :: GHC.Num.Natural.Natural) ((:*:) argL_0123456789876543210 argR_0123456789876543210 :: T a ()) (a_0123456789876543210 :: Symbol) = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 6))) (Apply (Apply (.@#@$) (Apply (Apply ShowsPrecSym0 (FromInteger 7)) argL_0123456789876543210)) (Apply (Apply (.@#@$) (Apply ShowStringSym0 " :*: ")) (Apply (Apply ShowsPrecSym0 (FromInteger 7)) argR_0123456789876543210)))) a_0123456789876543210 + type ShowsPrec_0123456789876543210Sym0 :: forall a. (~>) GHC.Num.Natural.Natural ((~>) (T a ()) ((~>) Symbol Symbol)) data ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (T a ()) ((~>) Symbol Symbol)) where ShowsPrec_0123456789876543210Sym0KindInference :: SameKind (Apply ShowsPrec_0123456789876543210Sym0 arg) (ShowsPrec_0123456789876543210Sym1 arg) => @@ -121,8 +124,8 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings ShowsPrec_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym0KindInference ()) - type ShowsPrec_0123456789876543210Sym1 :: GHC.Num.Natural.Natural - -> (~>) (T a ()) ((~>) Symbol Symbol) + type ShowsPrec_0123456789876543210Sym1 :: forall a. GHC.Num.Natural.Natural + -> (~>) (T a ()) ((~>) Symbol Symbol) data ShowsPrec_0123456789876543210Sym1 (a0123456789876543210 :: GHC.Num.Natural.Natural) :: (~>) (T a ()) ((~>) Symbol Symbol) where ShowsPrec_0123456789876543210Sym1KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -131,8 +134,8 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym1KindInference ()) - type ShowsPrec_0123456789876543210Sym2 :: GHC.Num.Natural.Natural - -> T a () -> (~>) Symbol Symbol + type ShowsPrec_0123456789876543210Sym2 :: forall a. GHC.Num.Natural.Natural + -> T a () -> (~>) Symbol Symbol data ShowsPrec_0123456789876543210Sym2 (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: T a ()) :: (~>) Symbol Symbol where ShowsPrec_0123456789876543210Sym2KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 arg) => @@ -141,8 +144,8 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym2KindInference ()) - type ShowsPrec_0123456789876543210Sym3 :: GHC.Num.Natural.Natural - -> T a () -> Symbol -> Symbol + type ShowsPrec_0123456789876543210Sym3 :: forall a. GHC.Num.Natural.Natural + -> T a () -> Symbol -> Symbol type family ShowsPrec_0123456789876543210Sym3 @a (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: T a ()) (a0123456789876543210 :: Symbol) :: Symbol where ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 a0123456789876543210 = ShowsPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210 instance PShow (T a ()) where @@ -325,11 +328,6 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations toSing S1 = SomeSing SS1 toSing S2 = SomeSing SS2 instance SEq a => SEq (T a ()) where - (%==) :: - forall (t1 :: T a ()) (t2 :: T a ()). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun (T a ()) ((~>) (T a ()) Bool) - -> Type) t1) t2) (%==) ((:%*:) (sA_0123456789876543210 :: Sing a_0123456789876543210) (sA_0123456789876543210 :: Sing a_0123456789876543210)) @@ -345,11 +343,6 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations (applySing (singFun2 @(==@#@$) (%==)) sA_0123456789876543210) sB_0123456789876543210) instance SOrd a => SOrd (T a ()) where - sCompare :: - forall (t1 :: T a ()) (t2 :: T a ()). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun (T a ()) ((~>) (T a ()) Ordering) - -> Type) t1) t2) sCompare ((:%*:) (sA_0123456789876543210 :: Sing a_0123456789876543210) (sA_0123456789876543210 :: Sing a_0123456789876543210)) @@ -373,14 +366,6 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations sB_0123456789876543210)) SNil)) instance SShow a => SShow (T a ()) where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: T a ()) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) (T a ()) ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec (sP_0123456789876543210 :: Sing p_0123456789876543210) ((:%*:) (sArgL_0123456789876543210 :: Sing argL_0123456789876543210) @@ -413,21 +398,11 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations sArgR_0123456789876543210)))) sA_0123456789876543210 instance SEq S where - (%==) :: - forall (t1 :: S) (t2 :: S). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun S ((~>) S Bool) - -> Type) t1) t2) (%==) SS1 SS1 = STrue (%==) SS1 SS2 = SFalse (%==) SS2 SS1 = SFalse (%==) SS2 SS2 = STrue instance SOrd S where - sCompare :: - forall (t1 :: S) (t2 :: S). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun S ((~>) S Ordering) - -> Type) t1) t2) sCompare SS1 SS1 = applySing (applySing @@ -443,14 +418,6 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations sCompare SS1 SS2 = SLT sCompare SS2 SS1 = SGT instance SShow S where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: S) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) S ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SS1 @@ -468,19 +435,9 @@ Singletons/StandaloneDeriving.hs:(0,0)-(0,0): Splicing declarations (singFun2 @ShowStringSym0 sShowString) (sing :: Sing "S2")) sA_0123456789876543210 instance SBounded S where - sMinBound :: Sing (MinBoundSym0 :: S) - sMaxBound :: Sing (MaxBoundSym0 :: S) sMinBound = SS1 sMaxBound = SS2 instance SEnum S where - sToEnum :: - forall (t :: GHC.Num.Natural.Natural). Sing t - -> Sing (Apply (ToEnumSym0 :: TyFun GHC.Num.Natural.Natural S - -> Type) t) - sFromEnum :: - forall (t :: S). Sing t - -> Sing (Apply (FromEnumSym0 :: TyFun S GHC.Num.Natural.Natural - -> Type) t) sToEnum (sN :: Sing n) = id @(Sing (Case_0123456789876543210 n (Apply (Apply (==@#@$) n) (FromInteger 0)))) diff --git a/singletons-base/tests/compile-and-dump/Singletons/Star.golden b/singletons-base/tests/compile-and-dump/Singletons/Star.golden index 683eb463..313f9e7a 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/Star.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/Star.golden @@ -265,11 +265,6 @@ Singletons/Star.hs:0:0:: Splicing declarations -> Type) where GHC.Internal.Data.Type.Coercion.testCoercion = decideCoercion instance (SEq Type, SEq Nat) => SEq Type where - (%==) :: - forall (t1 :: Type) (t2 :: Type). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun Type ((~>) Type Bool) - -> Type) t1) t2) (%==) SNat SNat = STrue (%==) SNat SInt = SFalse (%==) SNat SString = SFalse @@ -314,11 +309,6 @@ Singletons/Star.hs:0:0:: Splicing declarations (applySing (singFun2 @(==@#@$) (%==)) sA_0123456789876543210) sB_0123456789876543210) instance (SOrd Type, SOrd Nat) => SOrd Type where - sCompare :: - forall (t1 :: Type) (t2 :: Type). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun Type ((~>) Type Ordering) - -> Type) t1) t2) sCompare SNat SNat = applySing (applySing @@ -394,14 +384,6 @@ Singletons/Star.hs:0:0:: Splicing declarations sCompare (SVec _ _) SString = SGT sCompare (SVec _ _) (SMaybe _) = SGT instance (SShow Type, SShow Nat) => SShow Type where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: Type) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) Type ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SNat diff --git a/singletons-base/tests/compile-and-dump/Singletons/T136.golden b/singletons-base/tests/compile-and-dump/Singletons/T136.golden index 14b31142..f18966b6 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T136.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T136.golden @@ -113,20 +113,6 @@ Singletons/T136.hs:(0,0)-(0,0): Splicing declarations type ToEnum a = Apply ToEnum_0123456789876543210Sym0 a type FromEnum a = Apply FromEnum_0123456789876543210Sym0 a instance SEnum [Bool] where - sSucc :: - forall (t :: [Bool]). Sing t - -> Sing (Apply (SuccSym0 :: TyFun [Bool] [Bool] -> Type) t) - sPred :: - forall (t :: [Bool]). Sing t - -> Sing (Apply (PredSym0 :: TyFun [Bool] [Bool] -> Type) t) - sToEnum :: - forall (t :: GHC.Num.Natural.Natural). Sing t - -> Sing (Apply (ToEnumSym0 :: TyFun GHC.Num.Natural.Natural [Bool] - -> Type) t) - sFromEnum :: - forall (t :: [Bool]). Sing t - -> Sing (Apply (FromEnumSym0 :: TyFun [Bool] GHC.Num.Natural.Natural - -> Type) t) sSucc SNil = applySing (applySing (singFun2 @(:@#@$) SCons) STrue) SNil sSucc (SCons SFalse (sAs :: Sing as)) diff --git a/singletons-base/tests/compile-and-dump/Singletons/T136b.golden b/singletons-base/tests/compile-and-dump/Singletons/T136b.golden index 2985b700..dcf06da3 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T136b.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T136b.golden @@ -48,8 +48,5 @@ Singletons/T136b.hs:(0,0)-(0,0): Splicing declarations instance PC Bool where type Meth a = Apply Meth_0123456789876543210Sym0 a instance SC Bool where - sMeth :: - forall (t :: Bool). Sing t - -> Sing (Apply (MethSym0 :: TyFun Bool Bool -> Type) t) sMeth (sA_0123456789876543210 :: Sing a_0123456789876543210) = applySing (singFun1 @NotSym0 sNot) sA_0123456789876543210 diff --git a/singletons-base/tests/compile-and-dump/Singletons/T166.golden b/singletons-base/tests/compile-and-dump/Singletons/T166.golden index 58e11f43..c5a5e8c2 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T166.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T166.golden @@ -44,22 +44,22 @@ Singletons/T166.hs:(0,0)-(0,0): Splicing declarations type FooSym1 :: forall a. a -> [Bool] type family FooSym1 @a (a0123456789876543210 :: a) :: [Bool] where FooSym1 a0123456789876543210 = Foo a0123456789876543210 - type family Lambda_0123456789876543210 x0123456789876543210 s where - Lambda_0123456789876543210 x s = Apply (Apply (Apply FoosPrecSym0 (FromInteger 0)) x) s - data Lambda_0123456789876543210Sym0 x0123456789876543210 s0123456789876543210 + type family Lambda_0123456789876543210 a0123456789876543210 x0123456789876543210 s where + Lambda_0123456789876543210 a x s = Apply (Apply (Apply FoosPrecSym0 (FromInteger 0)) x) s + data Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 s0123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 x0123456789876543210) arg) (Lambda_0123456789876543210Sym1 x0123456789876543210 arg) => - Lambda_0123456789876543210Sym0 x0123456789876543210 s0123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 x0123456789876543210) s0123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 s0123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 x0123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210) arg) (Lambda_0123456789876543210Sym1 a0123456789876543210 x0123456789876543210 arg) => + Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 s0123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210) s0123456789876543210 = Lambda_0123456789876543210 a0123456789876543210 x0123456789876543210 s0123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - type family Lambda_0123456789876543210Sym1 x0123456789876543210 s0123456789876543210 where - Lambda_0123456789876543210Sym1 x0123456789876543210 s0123456789876543210 = Lambda_0123456789876543210 x0123456789876543210 s0123456789876543210 - type Foo_0123456789876543210 :: a -> [Bool] + type family Lambda_0123456789876543210Sym1 a0123456789876543210 x0123456789876543210 s0123456789876543210 where + Lambda_0123456789876543210Sym1 a0123456789876543210 x0123456789876543210 s0123456789876543210 = Lambda_0123456789876543210 a0123456789876543210 x0123456789876543210 s0123456789876543210 + type Foo_0123456789876543210 :: forall a. a -> [Bool] type family Foo_0123456789876543210 @a (a :: a) :: [Bool] where - Foo_0123456789876543210 x = Lambda_0123456789876543210Sym0 x - type Foo_0123456789876543210Sym0 :: (~>) a [Bool] + Foo_0123456789876543210 @a (x :: a) = Lambda_0123456789876543210Sym0 a x + type Foo_0123456789876543210Sym0 :: forall a. (~>) a [Bool] data Foo_0123456789876543210Sym0 :: (~>) a [Bool] where Foo_0123456789876543210Sym0KindInference :: SameKind (Apply Foo_0123456789876543210Sym0 arg) (Foo_0123456789876543210Sym1 arg) => @@ -68,7 +68,7 @@ Singletons/T166.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Foo_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Foo_0123456789876543210Sym0KindInference ()) - type Foo_0123456789876543210Sym1 :: a -> [Bool] + type Foo_0123456789876543210Sym1 :: forall a. a -> [Bool] type family Foo_0123456789876543210Sym1 @a (a0123456789876543210 :: a) :: [Bool] where Foo_0123456789876543210Sym1 a0123456789876543210 = Foo_0123456789876543210 a0123456789876543210 class PFoo a where @@ -92,7 +92,7 @@ Singletons/T166.hs:(0,0)-(0,0): Splicing declarations Sing t -> Sing (Apply FooSym0 t :: [Bool]) :: Type) sFoo (sX :: Sing x) = singFun1 - @(Lambda_0123456789876543210Sym0 x) + @(Lambda_0123456789876543210Sym0 a x) (\ sS -> case sS of (_ :: Sing s) @@ -133,12 +133,12 @@ Singletons/T166.hs:(0,0)-(0,0): Splicing declarations instance SFoo a => SingI (FooSym0 :: (~>) a [Bool]) where sing = singFun1 @FooSym0 sFoo Singletons/T166.hs:0:0: error: [GHC-83865] - • Expecting one more argument to ‘Lambda_0123456789876543210Sym0 x’ + • Expecting one more argument to ‘Lambda_0123456789876543210Sym0 a x’ Expected kind ‘[Bool]’, - but ‘Lambda_0123456789876543210Sym0 x’ has kind ‘TyFun - [Bool] [Bool] - -> Type’ - • In the type ‘Lambda_0123456789876543210Sym0 x’ + but ‘Lambda_0123456789876543210Sym0 a x’ has kind ‘TyFun + [Bool] [Bool] + -> Type’ + • In the type ‘Lambda_0123456789876543210Sym0 a x’ In the type family declaration for ‘Foo_0123456789876543210’ | 6 | $(singletonsOnly [d| diff --git a/singletons-base/tests/compile-and-dump/Singletons/T167.golden b/singletons-base/tests/compile-and-dump/Singletons/T167.golden index 6b62c012..0f54a9ea 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T167.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T167.golden @@ -55,10 +55,10 @@ Singletons/T167.hs:(0,0)-(0,0): Splicing declarations type FooListSym2 :: forall a. a -> [Bool] -> [Bool] type family FooListSym2 @a (a0123456789876543210 :: a) (a0123456789876543210 :: [Bool]) :: [Bool] where FooListSym2 a0123456789876543210 a0123456789876543210 = FooList a0123456789876543210 a0123456789876543210 - type FooList_0123456789876543210 :: a -> [Bool] -> [Bool] + type FooList_0123456789876543210 :: forall a. a -> [Bool] -> [Bool] type family FooList_0123456789876543210 @a (a :: a) (a :: [Bool]) :: [Bool] where - FooList_0123456789876543210 a_0123456789876543210 a_0123456789876543210 = Apply (Apply UndefinedSym0 a_0123456789876543210) a_0123456789876543210 - type FooList_0123456789876543210Sym0 :: (~>) a ((~>) [Bool] [Bool]) + FooList_0123456789876543210 @a (a_0123456789876543210 :: a) (a_0123456789876543210 :: [Bool]) = Apply (Apply UndefinedSym0 a_0123456789876543210) a_0123456789876543210 + type FooList_0123456789876543210Sym0 :: forall a. (~>) a ((~>) [Bool] [Bool]) data FooList_0123456789876543210Sym0 :: (~>) a ((~>) [Bool] [Bool]) where FooList_0123456789876543210Sym0KindInference :: SameKind (Apply FooList_0123456789876543210Sym0 arg) (FooList_0123456789876543210Sym1 arg) => @@ -67,7 +67,8 @@ Singletons/T167.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings FooList_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) FooList_0123456789876543210Sym0KindInference ()) - type FooList_0123456789876543210Sym1 :: a -> (~>) [Bool] [Bool] + type FooList_0123456789876543210Sym1 :: forall a. a + -> (~>) [Bool] [Bool] data FooList_0123456789876543210Sym1 (a0123456789876543210 :: a) :: (~>) [Bool] [Bool] where FooList_0123456789876543210Sym1KindInference :: SameKind (Apply (FooList_0123456789876543210Sym1 a0123456789876543210) arg) (FooList_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -76,18 +77,19 @@ Singletons/T167.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (FooList_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) FooList_0123456789876543210Sym1KindInference ()) - type FooList_0123456789876543210Sym2 :: a -> [Bool] -> [Bool] + type FooList_0123456789876543210Sym2 :: forall a. a + -> [Bool] -> [Bool] type family FooList_0123456789876543210Sym2 @a (a0123456789876543210 :: a) (a0123456789876543210 :: [Bool]) :: [Bool] where FooList_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = FooList_0123456789876543210 a0123456789876543210 a0123456789876543210 class PFoo a where type family FoosPrec (arg :: Natural) (arg :: a) (arg :: [Bool]) :: [Bool] type family FooList (arg :: a) (arg :: [Bool]) :: [Bool] type FooList a a = Apply (Apply FooList_0123456789876543210Sym0 a) a - type FoosPrec_0123456789876543210 :: Natural - -> [a] -> [Bool] -> [Bool] + type FoosPrec_0123456789876543210 :: forall a. Natural + -> [a] -> [Bool] -> [Bool] type family FoosPrec_0123456789876543210 @a (a :: Natural) (a :: [a]) (a :: [Bool]) :: [Bool] where - FoosPrec_0123456789876543210 _ a_0123456789876543210 a_0123456789876543210 = Apply (Apply FooListSym0 a_0123456789876543210) a_0123456789876543210 - type FoosPrec_0123456789876543210Sym0 :: (~>) Natural ((~>) [a] ((~>) [Bool] [Bool])) + FoosPrec_0123456789876543210 @a (_ :: Natural) (a_0123456789876543210 :: [a]) (a_0123456789876543210 :: [Bool]) = Apply (Apply FooListSym0 a_0123456789876543210) a_0123456789876543210 + type FoosPrec_0123456789876543210Sym0 :: forall a. (~>) Natural ((~>) [a] ((~>) [Bool] [Bool])) data FoosPrec_0123456789876543210Sym0 :: (~>) Natural ((~>) [a] ((~>) [Bool] [Bool])) where FoosPrec_0123456789876543210Sym0KindInference :: SameKind (Apply FoosPrec_0123456789876543210Sym0 arg) (FoosPrec_0123456789876543210Sym1 arg) => @@ -96,8 +98,8 @@ Singletons/T167.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings FoosPrec_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) FoosPrec_0123456789876543210Sym0KindInference ()) - type FoosPrec_0123456789876543210Sym1 :: Natural - -> (~>) [a] ((~>) [Bool] [Bool]) + type FoosPrec_0123456789876543210Sym1 :: forall a. Natural + -> (~>) [a] ((~>) [Bool] [Bool]) data FoosPrec_0123456789876543210Sym1 (a0123456789876543210 :: Natural) :: (~>) [a] ((~>) [Bool] [Bool]) where FoosPrec_0123456789876543210Sym1KindInference :: SameKind (Apply (FoosPrec_0123456789876543210Sym1 a0123456789876543210) arg) (FoosPrec_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -106,8 +108,8 @@ Singletons/T167.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (FoosPrec_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) FoosPrec_0123456789876543210Sym1KindInference ()) - type FoosPrec_0123456789876543210Sym2 :: Natural - -> [a] -> (~>) [Bool] [Bool] + type FoosPrec_0123456789876543210Sym2 :: forall a. Natural + -> [a] -> (~>) [Bool] [Bool] data FoosPrec_0123456789876543210Sym2 (a0123456789876543210 :: Natural) (a0123456789876543210 :: [a]) :: (~>) [Bool] [Bool] where FoosPrec_0123456789876543210Sym2KindInference :: SameKind (Apply (FoosPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) arg) (FoosPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 arg) => @@ -116,8 +118,8 @@ Singletons/T167.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (FoosPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) where suppressUnusedWarnings = snd ((,) FoosPrec_0123456789876543210Sym2KindInference ()) - type FoosPrec_0123456789876543210Sym3 :: Natural - -> [a] -> [Bool] -> [Bool] + type FoosPrec_0123456789876543210Sym3 :: forall a. Natural + -> [a] -> [Bool] -> [Bool] type family FoosPrec_0123456789876543210Sym3 @a (a0123456789876543210 :: Natural) (a0123456789876543210 :: [a]) (a0123456789876543210 :: [Bool]) :: [Bool] where FoosPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 a0123456789876543210 = FoosPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210 instance PFoo [a] where @@ -148,12 +150,6 @@ Singletons/T167.hs:(0,0)-(0,0): Splicing declarations (applySing sUndefined sA_0123456789876543210) sA_0123456789876543210 instance SFoo a => SFoo [a] where - sFoosPrec :: - (forall (t :: Natural) (t :: [a]) (t :: [Bool]). - Sing t - -> Sing t - -> Sing t - -> Sing (Apply (Apply (Apply FoosPrecSym0 t) t) t :: [Bool]) :: Type) sFoosPrec _ (sA_0123456789876543210 :: Sing a_0123456789876543210) diff --git a/singletons-base/tests/compile-and-dump/Singletons/T175.golden b/singletons-base/tests/compile-and-dump/Singletons/T175.golden index d4b22ccc..9662bf12 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T175.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T175.golden @@ -32,10 +32,10 @@ Singletons/T175.hs:(0,0)-(0,0): Splicing declarations type Quux1Sym0 :: forall a. a type family Quux1Sym0 @a :: a where Quux1Sym0 = Quux1 - type Quux1_0123456789876543210 :: a + type Quux1_0123456789876543210 :: forall a. a type family Quux1_0123456789876543210 @a :: a where - Quux1_0123456789876543210 = BazSym0 - type Quux1_0123456789876543210Sym0 :: a + Quux1_0123456789876543210 @a = BazSym0 + type Quux1_0123456789876543210Sym0 :: forall a. a type family Quux1_0123456789876543210Sym0 @a :: a where Quux1_0123456789876543210Sym0 = Quux1_0123456789876543210 class PBar1 a where diff --git a/singletons-base/tests/compile-and-dump/Singletons/T178.golden b/singletons-base/tests/compile-and-dump/Singletons/T178.golden index 755aab69..45601070 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T178.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T178.golden @@ -157,11 +157,6 @@ Singletons/T178.hs:(0,0)-(0,0): Splicing declarations toSing Opt = SomeSing SOpt toSing Many = SomeSing SMany instance SEq Occ where - (%==) :: - forall (t1 :: Occ) (t2 :: Occ). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun Occ ((~>) Occ Bool) - -> Type) t1) t2) (%==) SStr SStr = STrue (%==) SStr SOpt = SFalse (%==) SStr SMany = SFalse @@ -172,11 +167,6 @@ Singletons/T178.hs:(0,0)-(0,0): Splicing declarations (%==) SMany SOpt = SFalse (%==) SMany SMany = STrue instance SOrd Occ where - sCompare :: - forall (t1 :: Occ) (t2 :: Occ). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun Occ ((~>) Occ Ordering) - -> Type) t1) t2) sCompare SStr SStr = applySing (applySing @@ -202,12 +192,6 @@ Singletons/T178.hs:(0,0)-(0,0): Splicing declarations sCompare SMany SStr = SGT sCompare SMany SOpt = SGT instance SShow Occ where - sShowsPrec :: - forall (t1 :: Natural) (t2 :: Occ) (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun Natural ((~>) Occ ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SStr diff --git a/singletons-base/tests/compile-and-dump/Singletons/T187.golden b/singletons-base/tests/compile-and-dump/Singletons/T187.golden index 7578015f..fb4952a7 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T187.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T187.golden @@ -68,18 +68,8 @@ Singletons/T187.hs:(0,0)-(0,0): Splicing declarations fromSing x = case x of {} toSing x = SomeSing (case x of {}) instance SEq Empty where - (%==) :: - forall (t1 :: Empty) (t2 :: Empty). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun Empty ((~>) Empty Bool) - -> Type) t1) t2) (%==) _ _ = STrue instance SOrd Empty where - sCompare :: - forall (t1 :: Empty) (t2 :: Empty). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun Empty ((~>) Empty Ordering) - -> Type) t1) t2) sCompare _ _ = SEQ instance SDecide Empty where (%~) x _ = Proved (case x of {}) diff --git a/singletons-base/tests/compile-and-dump/Singletons/T190.golden b/singletons-base/tests/compile-and-dump/Singletons/T190.golden index e620ceae..f2bc8ad3 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T190.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T190.golden @@ -160,18 +160,8 @@ Singletons/T190.hs:0:0:: Splicing declarations fromSing ST = T toSing T = SomeSing ST instance SEq T where - (%==) :: - forall (t1 :: T) (t2 :: T). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun T ((~>) T Bool) - -> Type) t1) t2) (%==) ST ST = STrue instance SOrd T where - sCompare :: - forall (t1 :: T) (t2 :: T). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun T ((~>) T Ordering) - -> Type) t1) t2) sCompare ST ST = applySing (applySing @@ -179,14 +169,6 @@ Singletons/T190.hs:0:0:: Splicing declarations SEQ) SNil instance SEnum T where - sToEnum :: - forall (t :: GHC.Num.Natural.Natural). Sing t - -> Sing (Apply (Data.Singletons.Base.Enum.ToEnumSym0 :: TyFun GHC.Num.Natural.Natural T - -> Type) t) - sFromEnum :: - forall (t :: T). Sing t - -> Sing (Apply (Data.Singletons.Base.Enum.FromEnumSym0 :: TyFun T GHC.Num.Natural.Natural - -> Type) t) sToEnum (sN :: Sing n) = id @(Sing (Case_0123456789876543210 n (Apply (Apply (==@#@$) n) (FromInteger 0)))) @@ -201,19 +183,9 @@ Singletons/T190.hs:0:0:: Splicing declarations (singFun1 @ErrorSym0 sError) (sing :: Sing "toEnum: bad argument")) sFromEnum ST = sFromInteger (sing :: Sing 0) instance SBounded T where - sMinBound :: Sing (MinBoundSym0 :: T) - sMaxBound :: Sing (MaxBoundSym0 :: T) sMinBound = ST sMaxBound = ST instance SShow T where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: T) - (t3 :: GHC.Types.Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) T ((~>) GHC.Types.Symbol GHC.Types.Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ ST diff --git a/singletons-base/tests/compile-and-dump/Singletons/T271.golden b/singletons-base/tests/compile-and-dump/Singletons/T271.golden index 52870d77..f608b627 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T271.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T271.golden @@ -37,11 +37,12 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations type IdentitySym1 :: a -> Identity a type family IdentitySym1 @a (a0123456789876543210 :: a) :: Identity a where IdentitySym1 a0123456789876543210 = Identity a0123456789876543210 - type TFHelper_0123456789876543210 :: Constant a b - -> Constant a b -> Bool + type TFHelper_0123456789876543210 :: forall a b. Constant a b + -> Constant a b -> Bool type family TFHelper_0123456789876543210 @a @b (a :: Constant a b) (a :: Constant a b) :: Bool where - TFHelper_0123456789876543210 (Constant a_0123456789876543210) (Constant b_0123456789876543210) = Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210 - type TFHelper_0123456789876543210Sym0 :: (~>) (Constant a b) ((~>) (Constant a b) Bool) + TFHelper_0123456789876543210 @a @b (Constant a_0123456789876543210 :: Constant a b) (Constant b_0123456789876543210 :: Constant a b) = Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210 + type TFHelper_0123456789876543210Sym0 :: forall a + b. (~>) (Constant a b) ((~>) (Constant a b) Bool) data TFHelper_0123456789876543210Sym0 :: (~>) (Constant a b) ((~>) (Constant a b) Bool) where TFHelper_0123456789876543210Sym0KindInference :: SameKind (Apply TFHelper_0123456789876543210Sym0 arg) (TFHelper_0123456789876543210Sym1 arg) => @@ -50,8 +51,8 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings TFHelper_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym0KindInference ()) - type TFHelper_0123456789876543210Sym1 :: Constant a b - -> (~>) (Constant a b) Bool + type TFHelper_0123456789876543210Sym1 :: forall a b. Constant a b + -> (~>) (Constant a b) Bool data TFHelper_0123456789876543210Sym1 (a0123456789876543210 :: Constant a b) :: (~>) (Constant a b) Bool where TFHelper_0123456789876543210Sym1KindInference :: SameKind (Apply (TFHelper_0123456789876543210Sym1 a0123456789876543210) arg) (TFHelper_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -60,17 +61,18 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (TFHelper_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym1KindInference ()) - type TFHelper_0123456789876543210Sym2 :: Constant a b - -> Constant a b -> Bool + type TFHelper_0123456789876543210Sym2 :: forall a b. Constant a b + -> Constant a b -> Bool type family TFHelper_0123456789876543210Sym2 @a @b (a0123456789876543210 :: Constant a b) (a0123456789876543210 :: Constant a b) :: Bool where TFHelper_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = TFHelper_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PEq (Constant a b) where type (==) a a = Apply (Apply TFHelper_0123456789876543210Sym0 a) a - type Compare_0123456789876543210 :: Constant a b - -> Constant a b -> Ordering + type Compare_0123456789876543210 :: forall a b. Constant a b + -> Constant a b -> Ordering type family Compare_0123456789876543210 @a @b (a :: Constant a b) (a :: Constant a b) :: Ordering where - Compare_0123456789876543210 (Constant a_0123456789876543210) (Constant b_0123456789876543210) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0) - type Compare_0123456789876543210Sym0 :: (~>) (Constant a b) ((~>) (Constant a b) Ordering) + Compare_0123456789876543210 @a @b (Constant a_0123456789876543210 :: Constant a b) (Constant b_0123456789876543210 :: Constant a b) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0) + type Compare_0123456789876543210Sym0 :: forall a + b. (~>) (Constant a b) ((~>) (Constant a b) Ordering) data Compare_0123456789876543210Sym0 :: (~>) (Constant a b) ((~>) (Constant a b) Ordering) where Compare_0123456789876543210Sym0KindInference :: SameKind (Apply Compare_0123456789876543210Sym0 arg) (Compare_0123456789876543210Sym1 arg) => @@ -79,8 +81,8 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Compare_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Compare_0123456789876543210Sym0KindInference ()) - type Compare_0123456789876543210Sym1 :: Constant a b - -> (~>) (Constant a b) Ordering + type Compare_0123456789876543210Sym1 :: forall a b. Constant a b + -> (~>) (Constant a b) Ordering data Compare_0123456789876543210Sym1 (a0123456789876543210 :: Constant a b) :: (~>) (Constant a b) Ordering where Compare_0123456789876543210Sym1KindInference :: SameKind (Apply (Compare_0123456789876543210Sym1 a0123456789876543210) arg) (Compare_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -89,17 +91,17 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Compare_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Compare_0123456789876543210Sym1KindInference ()) - type Compare_0123456789876543210Sym2 :: Constant a b - -> Constant a b -> Ordering + type Compare_0123456789876543210Sym2 :: forall a b. Constant a b + -> Constant a b -> Ordering type family Compare_0123456789876543210Sym2 @a @b (a0123456789876543210 :: Constant a b) (a0123456789876543210 :: Constant a b) :: Ordering where Compare_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Compare_0123456789876543210 a0123456789876543210 a0123456789876543210 instance POrd (Constant a b) where type Compare a a = Apply (Apply Compare_0123456789876543210Sym0 a) a - type TFHelper_0123456789876543210 :: Identity a - -> Identity a -> Bool + type TFHelper_0123456789876543210 :: forall a. Identity a + -> Identity a -> Bool type family TFHelper_0123456789876543210 @a (a :: Identity a) (a :: Identity a) :: Bool where - TFHelper_0123456789876543210 (Identity a_0123456789876543210) (Identity b_0123456789876543210) = Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210 - type TFHelper_0123456789876543210Sym0 :: (~>) (Identity a) ((~>) (Identity a) Bool) + TFHelper_0123456789876543210 @a (Identity a_0123456789876543210 :: Identity a) (Identity b_0123456789876543210 :: Identity a) = Apply (Apply (==@#@$) a_0123456789876543210) b_0123456789876543210 + type TFHelper_0123456789876543210Sym0 :: forall a. (~>) (Identity a) ((~>) (Identity a) Bool) data TFHelper_0123456789876543210Sym0 :: (~>) (Identity a) ((~>) (Identity a) Bool) where TFHelper_0123456789876543210Sym0KindInference :: SameKind (Apply TFHelper_0123456789876543210Sym0 arg) (TFHelper_0123456789876543210Sym1 arg) => @@ -108,8 +110,8 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings TFHelper_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym0KindInference ()) - type TFHelper_0123456789876543210Sym1 :: Identity a - -> (~>) (Identity a) Bool + type TFHelper_0123456789876543210Sym1 :: forall a. Identity a + -> (~>) (Identity a) Bool data TFHelper_0123456789876543210Sym1 (a0123456789876543210 :: Identity a) :: (~>) (Identity a) Bool where TFHelper_0123456789876543210Sym1KindInference :: SameKind (Apply (TFHelper_0123456789876543210Sym1 a0123456789876543210) arg) (TFHelper_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -118,17 +120,17 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (TFHelper_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym1KindInference ()) - type TFHelper_0123456789876543210Sym2 :: Identity a - -> Identity a -> Bool + type TFHelper_0123456789876543210Sym2 :: forall a. Identity a + -> Identity a -> Bool type family TFHelper_0123456789876543210Sym2 @a (a0123456789876543210 :: Identity a) (a0123456789876543210 :: Identity a) :: Bool where TFHelper_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = TFHelper_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PEq (Identity a) where type (==) a a = Apply (Apply TFHelper_0123456789876543210Sym0 a) a - type Compare_0123456789876543210 :: Identity a - -> Identity a -> Ordering + type Compare_0123456789876543210 :: forall a. Identity a + -> Identity a -> Ordering type family Compare_0123456789876543210 @a (a :: Identity a) (a :: Identity a) :: Ordering where - Compare_0123456789876543210 (Identity a_0123456789876543210) (Identity b_0123456789876543210) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0) - type Compare_0123456789876543210Sym0 :: (~>) (Identity a) ((~>) (Identity a) Ordering) + Compare_0123456789876543210 @a (Identity a_0123456789876543210 :: Identity a) (Identity b_0123456789876543210 :: Identity a) = Apply (Apply (Apply FoldlSym0 (<>@#@$)) EQSym0) (Apply (Apply (:@#@$) (Apply (Apply CompareSym0 a_0123456789876543210) b_0123456789876543210)) NilSym0) + type Compare_0123456789876543210Sym0 :: forall a. (~>) (Identity a) ((~>) (Identity a) Ordering) data Compare_0123456789876543210Sym0 :: (~>) (Identity a) ((~>) (Identity a) Ordering) where Compare_0123456789876543210Sym0KindInference :: SameKind (Apply Compare_0123456789876543210Sym0 arg) (Compare_0123456789876543210Sym1 arg) => @@ -137,8 +139,8 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Compare_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Compare_0123456789876543210Sym0KindInference ()) - type Compare_0123456789876543210Sym1 :: Identity a - -> (~>) (Identity a) Ordering + type Compare_0123456789876543210Sym1 :: forall a. Identity a + -> (~>) (Identity a) Ordering data Compare_0123456789876543210Sym1 (a0123456789876543210 :: Identity a) :: (~>) (Identity a) Ordering where Compare_0123456789876543210Sym1KindInference :: SameKind (Apply (Compare_0123456789876543210Sym1 a0123456789876543210) arg) (Compare_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -147,8 +149,8 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Compare_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Compare_0123456789876543210Sym1KindInference ()) - type Compare_0123456789876543210Sym2 :: Identity a - -> Identity a -> Ordering + type Compare_0123456789876543210Sym2 :: forall a. Identity a + -> Identity a -> Ordering type family Compare_0123456789876543210Sym2 @a (a0123456789876543210 :: Identity a) (a0123456789876543210 :: Identity a) :: Ordering where Compare_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Compare_0123456789876543210 a0123456789876543210 a0123456789876543210 instance POrd (Identity a) where @@ -177,11 +179,6 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations = case toSing b :: SomeSing a of SomeSing c -> SomeSing (SIdentity c) instance SEq a => SEq (Constant a b) where - (%==) :: - forall (t1 :: Constant a b) (t2 :: Constant a b). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun (Constant a b) ((~>) (Constant a b) Bool) - -> Type) t1) t2) (%==) (SConstant (sA_0123456789876543210 :: Sing a_0123456789876543210)) (SConstant (sB_0123456789876543210 :: Sing b_0123456789876543210)) @@ -189,11 +186,6 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations (applySing (singFun2 @(==@#@$) (%==)) sA_0123456789876543210) sB_0123456789876543210 instance SOrd a => SOrd (Constant a b) where - sCompare :: - forall (t1 :: Constant a b) (t2 :: Constant a b). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun (Constant a b) ((~>) (Constant a b) Ordering) - -> Type) t1) t2) sCompare (SConstant (sA_0123456789876543210 :: Sing a_0123456789876543210)) (SConstant (sB_0123456789876543210 :: Sing b_0123456789876543210)) @@ -209,11 +201,6 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations sB_0123456789876543210)) SNil) instance SEq a => SEq (Identity a) where - (%==) :: - forall (t1 :: Identity a) (t2 :: Identity a). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun (Identity a) ((~>) (Identity a) Bool) - -> Type) t1) t2) (%==) (SIdentity (sA_0123456789876543210 :: Sing a_0123456789876543210)) (SIdentity (sB_0123456789876543210 :: Sing b_0123456789876543210)) @@ -221,11 +208,6 @@ Singletons/T271.hs:(0,0)-(0,0): Splicing declarations (applySing (singFun2 @(==@#@$) (%==)) sA_0123456789876543210) sB_0123456789876543210 instance SOrd a => SOrd (Identity a) where - sCompare :: - forall (t1 :: Identity a) (t2 :: Identity a). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun (Identity a) ((~>) (Identity a) Ordering) - -> Type) t1) t2) sCompare (SIdentity (sA_0123456789876543210 :: Sing a_0123456789876543210)) (SIdentity (sB_0123456789876543210 :: Sing b_0123456789876543210)) diff --git a/singletons-base/tests/compile-and-dump/Singletons/T287.golden b/singletons-base/tests/compile-and-dump/Singletons/T287.golden index 265b4c4c..a3b9ddb1 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T287.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T287.golden @@ -31,23 +31,24 @@ Singletons/T287.hs:(0,0)-(0,0): Splicing declarations (<<>>@#@$$$) a0123456789876543210 a0123456789876543210 = (<<>>) a0123456789876543210 a0123456789876543210 class PS a where type family (<<>>) (arg :: a) (arg :: a) :: a - type family Lambda_0123456789876543210 f0123456789876543210 g0123456789876543210 x where - Lambda_0123456789876543210 f g x = Apply (Apply (<<>>@#@$) (Apply f x)) (Apply g x) - data Lambda_0123456789876543210Sym0 f0123456789876543210 g0123456789876543210 x0123456789876543210 + type family Lambda_0123456789876543210 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210 x where + Lambda_0123456789876543210 a b f g x = Apply (Apply (<<>>@#@$) (Apply f x)) (Apply g x) + data Lambda_0123456789876543210Sym0 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210 x0123456789876543210 where - Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 f0123456789876543210 g0123456789876543210) arg) (Lambda_0123456789876543210Sym1 f0123456789876543210 g0123456789876543210 arg) => - Lambda_0123456789876543210Sym0 f0123456789876543210 g0123456789876543210 x0123456789876543210 - type instance Apply (Lambda_0123456789876543210Sym0 f0123456789876543210 g0123456789876543210) x0123456789876543210 = Lambda_0123456789876543210 f0123456789876543210 g0123456789876543210 x0123456789876543210 - instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 f0123456789876543210 g0123456789876543210) where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210) arg) (Lambda_0123456789876543210Sym1 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210 arg) => + Lambda_0123456789876543210Sym0 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210 x0123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210) x0123456789876543210 = Lambda_0123456789876543210 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210 x0123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210) where suppressUnusedWarnings = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) - type family Lambda_0123456789876543210Sym1 f0123456789876543210 g0123456789876543210 x0123456789876543210 where - Lambda_0123456789876543210Sym1 f0123456789876543210 g0123456789876543210 x0123456789876543210 = Lambda_0123456789876543210 f0123456789876543210 g0123456789876543210 x0123456789876543210 - type TFHelper_0123456789876543210 :: (~>) a b - -> (~>) a b -> (~>) a b + type family Lambda_0123456789876543210Sym1 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210 x0123456789876543210 where + Lambda_0123456789876543210Sym1 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210 x0123456789876543210 = Lambda_0123456789876543210 a0123456789876543210 b0123456789876543210 f0123456789876543210 g0123456789876543210 x0123456789876543210 + type TFHelper_0123456789876543210 :: forall a b. (~>) a b + -> (~>) a b -> (~>) a b type family TFHelper_0123456789876543210 @a @b (a :: (~>) a b) (a :: (~>) a b) :: (~>) a b where - TFHelper_0123456789876543210 f g = Lambda_0123456789876543210Sym0 f g - type TFHelper_0123456789876543210Sym0 :: (~>) ((~>) a b) ((~>) ((~>) a b) ((~>) a b)) + TFHelper_0123456789876543210 @a @b (f :: (~>) a b) (g :: (~>) a b) = Lambda_0123456789876543210Sym0 a b f g + type TFHelper_0123456789876543210Sym0 :: forall a + b. (~>) ((~>) a b) ((~>) ((~>) a b) ((~>) a b)) data TFHelper_0123456789876543210Sym0 :: (~>) ((~>) a b) ((~>) ((~>) a b) ((~>) a b)) where TFHelper_0123456789876543210Sym0KindInference :: SameKind (Apply TFHelper_0123456789876543210Sym0 arg) (TFHelper_0123456789876543210Sym1 arg) => @@ -56,8 +57,8 @@ Singletons/T287.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings TFHelper_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym0KindInference ()) - type TFHelper_0123456789876543210Sym1 :: (~>) a b - -> (~>) ((~>) a b) ((~>) a b) + type TFHelper_0123456789876543210Sym1 :: forall a b. (~>) a b + -> (~>) ((~>) a b) ((~>) a b) data TFHelper_0123456789876543210Sym1 (a0123456789876543210 :: (~>) a b) :: (~>) ((~>) a b) ((~>) a b) where TFHelper_0123456789876543210Sym1KindInference :: SameKind (Apply (TFHelper_0123456789876543210Sym1 a0123456789876543210) arg) (TFHelper_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -66,8 +67,8 @@ Singletons/T287.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (TFHelper_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) TFHelper_0123456789876543210Sym1KindInference ()) - type TFHelper_0123456789876543210Sym2 :: (~>) a b - -> (~>) a b -> (~>) a b + type TFHelper_0123456789876543210Sym2 :: forall a b. (~>) a b + -> (~>) a b -> (~>) a b type family TFHelper_0123456789876543210Sym2 @a @b (a0123456789876543210 :: (~>) a b) (a0123456789876543210 :: (~>) a b) :: (~>) a b where TFHelper_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = TFHelper_0123456789876543210 a0123456789876543210 a0123456789876543210 instance PS ((~>) a b) where @@ -78,14 +79,9 @@ Singletons/T287.hs:(0,0)-(0,0): Splicing declarations Sing t -> Sing t -> Sing (Apply (Apply (<<>>@#@$) t) t :: a) :: Type) instance SS b => SS ((~>) a b) where - (%<<>>) :: - (forall (t :: (~>) a b) (t :: (~>) a b). - Sing t - -> Sing t - -> Sing (Apply (Apply (<<>>@#@$) t) t :: (~>) a b) :: Type) (%<<>>) (sF :: Sing f) (sG :: Sing g) = singFun1 - @(Lambda_0123456789876543210Sym0 f g) + @(Lambda_0123456789876543210Sym0 a b f g) (\ sX -> case sX of (_ :: Sing x) diff --git a/singletons-base/tests/compile-and-dump/Singletons/T312.golden b/singletons-base/tests/compile-and-dump/Singletons/T312.golden index fc31bcb8..569a3ba5 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T312.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T312.golden @@ -57,10 +57,10 @@ Singletons/T312.hs:(0,0)-(0,0): Splicing declarations type BazSym2 :: forall a b. a -> b -> b type family BazSym2 @a @b (a0123456789876543210 :: a) (a0123456789876543210 :: b) :: b where BazSym2 a0123456789876543210 a0123456789876543210 = Baz a0123456789876543210 a0123456789876543210 - type Bar_0123456789876543210 :: a -> b -> b + type Bar_0123456789876543210 :: forall a b. a -> b -> b type family Bar_0123456789876543210 @a @b (a :: a) (a :: b) :: b where - Bar_0123456789876543210 _ x = x - type Bar_0123456789876543210Sym0 :: (~>) a ((~>) b b) + Bar_0123456789876543210 @a @b (_ :: a) (x :: b) = x + type Bar_0123456789876543210Sym0 :: forall a b. (~>) a ((~>) b b) data Bar_0123456789876543210Sym0 :: (~>) a ((~>) b b) where Bar_0123456789876543210Sym0KindInference :: SameKind (Apply Bar_0123456789876543210Sym0 arg) (Bar_0123456789876543210Sym1 arg) => @@ -69,7 +69,7 @@ Singletons/T312.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Bar_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Bar_0123456789876543210Sym0KindInference ()) - type Bar_0123456789876543210Sym1 :: a -> (~>) b b + type Bar_0123456789876543210Sym1 :: forall a b. a -> (~>) b b data Bar_0123456789876543210Sym1 (a0123456789876543210 :: a) :: (~>) b b where Bar_0123456789876543210Sym1KindInference :: SameKind (Apply (Bar_0123456789876543210Sym1 a0123456789876543210) arg) (Bar_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -78,33 +78,33 @@ Singletons/T312.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Bar_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Bar_0123456789876543210Sym1KindInference ()) - type Bar_0123456789876543210Sym2 :: a -> b -> b + type Bar_0123456789876543210Sym2 :: forall a b. a -> b -> b type family Bar_0123456789876543210Sym2 @a @b (a0123456789876543210 :: a) (a0123456789876543210 :: b) :: b where Bar_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Bar_0123456789876543210 a0123456789876543210 a0123456789876543210 - data Let0123456789876543210HSym0 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 :: (~>) c0123456789876543210 ((~>) b0123456789876543210 b0123456789876543210) + data Let0123456789876543210HSym0 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 :: (~>) c0123456789876543210 ((~>) b0123456789876543210 b0123456789876543210) where - Let0123456789876543210HSym0KindInference :: SameKind (Apply (Let0123456789876543210HSym0 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Let0123456789876543210HSym1 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => - Let0123456789876543210HSym0 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 - type instance Apply (Let0123456789876543210HSym0 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) a0123456789876543210 = Let0123456789876543210HSym1 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 - instance SuppressUnusedWarnings (Let0123456789876543210HSym0 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where + Let0123456789876543210HSym0KindInference :: SameKind (Apply (Let0123456789876543210HSym0 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) arg) (Let0123456789876543210HSym1 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 arg) => + Let0123456789876543210HSym0 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 + type instance Apply (Let0123456789876543210HSym0 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) a0123456789876543210 = Let0123456789876543210HSym1 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings (Let0123456789876543210HSym0 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210) where suppressUnusedWarnings = snd ((,) Let0123456789876543210HSym0KindInference ()) - data Let0123456789876543210HSym1 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 (a0123456789876543210 :: c0123456789876543210) :: (~>) b0123456789876543210 b0123456789876543210 + data Let0123456789876543210HSym1 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 (a0123456789876543210 :: c0123456789876543210) :: (~>) b0123456789876543210 b0123456789876543210 where - Let0123456789876543210HSym1KindInference :: SameKind (Apply (Let0123456789876543210HSym1 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210) arg) (Let0123456789876543210HSym2 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 arg) => - Let0123456789876543210HSym1 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 a0123456789876543210 - type instance Apply (Let0123456789876543210HSym1 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210) a0123456789876543210 = Let0123456789876543210H a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 a0123456789876543210 - instance SuppressUnusedWarnings (Let0123456789876543210HSym1 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210) where + Let0123456789876543210HSym1KindInference :: SameKind (Apply (Let0123456789876543210HSym1 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210) arg) (Let0123456789876543210HSym2 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 arg) => + Let0123456789876543210HSym1 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 a0123456789876543210 + type instance Apply (Let0123456789876543210HSym1 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210) a0123456789876543210 = Let0123456789876543210H a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings (Let0123456789876543210HSym1 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Let0123456789876543210HSym1KindInference ()) - type family Let0123456789876543210HSym2 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 (a0123456789876543210 :: c0123456789876543210) (a0123456789876543210 :: b0123456789876543210) :: b0123456789876543210 where - Let0123456789876543210HSym2 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 a0123456789876543210 = Let0123456789876543210H a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 a0123456789876543210 - type family Let0123456789876543210H a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 (a :: c) (a :: b) :: b where - Let0123456789876543210H a_0123456789876543210 a_0123456789876543210 (_ :: c) (x :: b) = x - type Baz_0123456789876543210 :: a -> b -> b + type family Let0123456789876543210HSym2 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 (a0123456789876543210 :: c0123456789876543210) (a0123456789876543210 :: b0123456789876543210) :: b0123456789876543210 where + Let0123456789876543210HSym2 a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 a0123456789876543210 = Let0123456789876543210H a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 a0123456789876543210 a0123456789876543210 + type family Let0123456789876543210H a0123456789876543210 b0123456789876543210 a_01234567898765432100123456789876543210 a_01234567898765432100123456789876543210 (a :: c) (a :: b0123456789876543210) :: b0123456789876543210 where + Let0123456789876543210H a b a_0123456789876543210 a_0123456789876543210 (_ :: c) (x :: b) = x + type Baz_0123456789876543210 :: forall a b. a -> b -> b type family Baz_0123456789876543210 @a @b (a :: a) (a :: b) :: b where - Baz_0123456789876543210 a_0123456789876543210 a_0123456789876543210 = Apply (Apply (Let0123456789876543210HSym0 a_0123456789876543210 a_0123456789876543210) a_0123456789876543210) a_0123456789876543210 - type Baz_0123456789876543210Sym0 :: (~>) a ((~>) b b) + Baz_0123456789876543210 @a @b (a_0123456789876543210 :: a) (a_0123456789876543210 :: b) = Apply (Apply (Let0123456789876543210HSym0 a b a_0123456789876543210 a_0123456789876543210) a_0123456789876543210) a_0123456789876543210 + type Baz_0123456789876543210Sym0 :: forall a b. (~>) a ((~>) b b) data Baz_0123456789876543210Sym0 :: (~>) a ((~>) b b) where Baz_0123456789876543210Sym0KindInference :: SameKind (Apply Baz_0123456789876543210Sym0 arg) (Baz_0123456789876543210Sym1 arg) => @@ -113,7 +113,7 @@ Singletons/T312.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Baz_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Baz_0123456789876543210Sym0KindInference ()) - type Baz_0123456789876543210Sym1 :: a -> (~>) b b + type Baz_0123456789876543210Sym1 :: forall a b. a -> (~>) b b data Baz_0123456789876543210Sym1 (a0123456789876543210 :: a) :: (~>) b b where Baz_0123456789876543210Sym1KindInference :: SameKind (Apply (Baz_0123456789876543210Sym1 a0123456789876543210) arg) (Baz_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -122,7 +122,7 @@ Singletons/T312.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (Baz_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) Baz_0123456789876543210Sym1KindInference ()) - type Baz_0123456789876543210Sym2 :: a -> b -> b + type Baz_0123456789876543210Sym2 :: forall a b. a -> b -> b type family Baz_0123456789876543210Sym2 @a @b (a0123456789876543210 :: a) (a0123456789876543210 :: b) :: b where Baz_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = Baz_0123456789876543210 a0123456789876543210 a0123456789876543210 class PFoo a where @@ -157,11 +157,11 @@ Singletons/T312.hs:(0,0)-(0,0): Splicing declarations sH :: forall c (t :: c) (t :: b). Sing t -> Sing t - -> Sing (Apply (Apply (Let0123456789876543210HSym0 a_0123456789876543210 a_0123456789876543210) t) t :: b) + -> Sing (Apply (Apply (Let0123456789876543210HSym0 a b a_0123456789876543210 a_0123456789876543210) t) t :: b) sH _ (sX :: Sing x) = sX in singFun2 - @(Let0123456789876543210HSym0 a_0123456789876543210 a_0123456789876543210) + @(Let0123456789876543210HSym0 a b a_0123456789876543210 a_0123456789876543210) sH) sA_0123456789876543210) sA_0123456789876543210 diff --git a/singletons-base/tests/compile-and-dump/Singletons/T358.golden b/singletons-base/tests/compile-and-dump/Singletons/T358.golden index e9c8b5b0..9749f111 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T358.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T358.golden @@ -55,18 +55,18 @@ Singletons/T358.hs:(0,0)-(0,0): Splicing declarations class PC2 a where type family Method2a (arg :: b) :: a type family Method2b (arg :: b) :: a - type Method1_0123456789876543210 :: [a] + type Method1_0123456789876543210 :: forall a. [a] type family Method1_0123456789876543210 @a :: [a] where - Method1_0123456789876543210 = NilSym0 - type Method1_0123456789876543210Sym0 :: [a] + Method1_0123456789876543210 @a = NilSym0 + type Method1_0123456789876543210Sym0 :: forall a. [a] type family Method1_0123456789876543210Sym0 @a :: [a] where Method1_0123456789876543210Sym0 = Method1_0123456789876543210 instance PC1 [] where type Method1 = Method1_0123456789876543210Sym0 - type Method2a_0123456789876543210 :: b -> [a] + type Method2a_0123456789876543210 :: forall b a. b -> [a] type family Method2a_0123456789876543210 @b @a (a :: b) :: [a] where - Method2a_0123456789876543210 _ = NilSym0 - type Method2a_0123456789876543210Sym0 :: (~>) b [a] + Method2a_0123456789876543210 @b @a (_ :: b) = NilSym0 + type Method2a_0123456789876543210Sym0 :: forall b a. (~>) b [a] data Method2a_0123456789876543210Sym0 :: (~>) b [a] where Method2a_0123456789876543210Sym0KindInference :: SameKind (Apply Method2a_0123456789876543210Sym0 arg) (Method2a_0123456789876543210Sym1 arg) => @@ -75,13 +75,13 @@ Singletons/T358.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Method2a_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Method2a_0123456789876543210Sym0KindInference ()) - type Method2a_0123456789876543210Sym1 :: b -> [a] + type Method2a_0123456789876543210Sym1 :: forall b a. b -> [a] type family Method2a_0123456789876543210Sym1 @b @a (a0123456789876543210 :: b) :: [a] where Method2a_0123456789876543210Sym1 a0123456789876543210 = Method2a_0123456789876543210 a0123456789876543210 - type Method2b_0123456789876543210 :: b -> [a] + type Method2b_0123456789876543210 :: forall b a. b -> [a] type family Method2b_0123456789876543210 @b @a (a :: b) :: [a] where - Method2b_0123456789876543210 _ = NilSym0 - type Method2b_0123456789876543210Sym0 :: (~>) b [a] + Method2b_0123456789876543210 @b @a (_ :: b) = NilSym0 + type Method2b_0123456789876543210Sym0 :: forall b a. (~>) b [a] data Method2b_0123456789876543210Sym0 :: (~>) b [a] where Method2b_0123456789876543210Sym0KindInference :: SameKind (Apply Method2b_0123456789876543210Sym0 arg) (Method2b_0123456789876543210Sym1 arg) => @@ -90,7 +90,7 @@ Singletons/T358.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings Method2b_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) Method2b_0123456789876543210Sym0KindInference ()) - type Method2b_0123456789876543210Sym1 :: b -> [a] + type Method2b_0123456789876543210Sym1 :: forall b a. b -> [a] type family Method2b_0123456789876543210Sym1 @b @a (a0123456789876543210 :: b) :: [a] where Method2b_0123456789876543210Sym1 a0123456789876543210 = Method2b_0123456789876543210 a0123456789876543210 instance PC2 [a] where @@ -107,8 +107,6 @@ Singletons/T358.hs:(0,0)-(0,0): Splicing declarations sMethod1 :: (Sing (Method1Sym0 :: [a]) :: Type) sMethod1 = SNil instance SC2 [a] where - sMethod2a :: - forall b (t :: b). Sing t -> Sing (Apply Method2aSym0 t :: [a]) sMethod2b :: forall b (t :: b). Sing t -> Sing (Apply Method2bSym0 t :: [a]) sMethod2a _ = SNil diff --git a/singletons-base/tests/compile-and-dump/Singletons/T371.golden b/singletons-base/tests/compile-and-dump/Singletons/T371.golden index 2b1ffead..7c44e989 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T371.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T371.golden @@ -41,12 +41,12 @@ Singletons/T371.hs:(0,0)-(0,0): Splicing declarations type Y2Sym1 :: forall (a :: Type). X a -> Y a type family Y2Sym1 @(a :: Type) (a0123456789876543210 :: X a) :: Y a where Y2Sym1 a0123456789876543210 = Y2 a0123456789876543210 - type ShowsPrec_0123456789876543210 :: GHC.Num.Natural.Natural - -> X a -> GHC.Types.Symbol -> GHC.Types.Symbol + type ShowsPrec_0123456789876543210 :: forall a. GHC.Num.Natural.Natural + -> X a -> GHC.Types.Symbol -> GHC.Types.Symbol type family ShowsPrec_0123456789876543210 @a (a :: GHC.Num.Natural.Natural) (a :: X a) (a :: GHC.Types.Symbol) :: GHC.Types.Symbol where - ShowsPrec_0123456789876543210 _ X1 a_0123456789876543210 = Apply (Apply ShowStringSym0 "X1") a_0123456789876543210 - ShowsPrec_0123456789876543210 p_0123456789876543210 (X2 arg_0123456789876543210) a_0123456789876543210 = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "X2 ")) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))) a_0123456789876543210 - type ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (X a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) + ShowsPrec_0123456789876543210 @a (_ :: GHC.Num.Natural.Natural) (X1 :: X a) (a_0123456789876543210 :: GHC.Types.Symbol) = Apply (Apply ShowStringSym0 "X1") a_0123456789876543210 + ShowsPrec_0123456789876543210 @a (p_0123456789876543210 :: GHC.Num.Natural.Natural) (X2 arg_0123456789876543210 :: X a) (a_0123456789876543210 :: GHC.Types.Symbol) = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "X2 ")) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))) a_0123456789876543210 + type ShowsPrec_0123456789876543210Sym0 :: forall a. (~>) GHC.Num.Natural.Natural ((~>) (X a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) data ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (X a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) where ShowsPrec_0123456789876543210Sym0KindInference :: SameKind (Apply ShowsPrec_0123456789876543210Sym0 arg) (ShowsPrec_0123456789876543210Sym1 arg) => @@ -55,8 +55,8 @@ Singletons/T371.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings ShowsPrec_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym0KindInference ()) - type ShowsPrec_0123456789876543210Sym1 :: GHC.Num.Natural.Natural - -> (~>) (X a) ((~>) GHC.Types.Symbol GHC.Types.Symbol) + type ShowsPrec_0123456789876543210Sym1 :: forall a. GHC.Num.Natural.Natural + -> (~>) (X a) ((~>) GHC.Types.Symbol GHC.Types.Symbol) data ShowsPrec_0123456789876543210Sym1 (a0123456789876543210 :: GHC.Num.Natural.Natural) :: (~>) (X a) ((~>) GHC.Types.Symbol GHC.Types.Symbol) where ShowsPrec_0123456789876543210Sym1KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -65,8 +65,9 @@ Singletons/T371.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym1KindInference ()) - type ShowsPrec_0123456789876543210Sym2 :: GHC.Num.Natural.Natural - -> X a -> (~>) GHC.Types.Symbol GHC.Types.Symbol + type ShowsPrec_0123456789876543210Sym2 :: forall a. GHC.Num.Natural.Natural + -> X a + -> (~>) GHC.Types.Symbol GHC.Types.Symbol data ShowsPrec_0123456789876543210Sym2 (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: X a) :: (~>) GHC.Types.Symbol GHC.Types.Symbol where ShowsPrec_0123456789876543210Sym2KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 arg) => @@ -75,18 +76,19 @@ Singletons/T371.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym2KindInference ()) - type ShowsPrec_0123456789876543210Sym3 :: GHC.Num.Natural.Natural - -> X a -> GHC.Types.Symbol -> GHC.Types.Symbol + type ShowsPrec_0123456789876543210Sym3 :: forall a. GHC.Num.Natural.Natural + -> X a + -> GHC.Types.Symbol -> GHC.Types.Symbol type family ShowsPrec_0123456789876543210Sym3 @a (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: X a) (a0123456789876543210 :: GHC.Types.Symbol) :: GHC.Types.Symbol where ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 a0123456789876543210 = ShowsPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210 instance PShow (X a) where type ShowsPrec a a a = Apply (Apply (Apply ShowsPrec_0123456789876543210Sym0 a) a) a - type ShowsPrec_0123456789876543210 :: GHC.Num.Natural.Natural - -> Y a -> GHC.Types.Symbol -> GHC.Types.Symbol + type ShowsPrec_0123456789876543210 :: forall a. GHC.Num.Natural.Natural + -> Y a -> GHC.Types.Symbol -> GHC.Types.Symbol type family ShowsPrec_0123456789876543210 @a (a :: GHC.Num.Natural.Natural) (a :: Y a) (a :: GHC.Types.Symbol) :: GHC.Types.Symbol where - ShowsPrec_0123456789876543210 _ Y1 a_0123456789876543210 = Apply (Apply ShowStringSym0 "Y1") a_0123456789876543210 - ShowsPrec_0123456789876543210 p_0123456789876543210 (Y2 arg_0123456789876543210) a_0123456789876543210 = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "Y2 ")) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))) a_0123456789876543210 - type ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (Y a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) + ShowsPrec_0123456789876543210 @a (_ :: GHC.Num.Natural.Natural) (Y1 :: Y a) (a_0123456789876543210 :: GHC.Types.Symbol) = Apply (Apply ShowStringSym0 "Y1") a_0123456789876543210 + ShowsPrec_0123456789876543210 @a (p_0123456789876543210 :: GHC.Num.Natural.Natural) (Y2 arg_0123456789876543210 :: Y a) (a_0123456789876543210 :: GHC.Types.Symbol) = Apply (Apply (Apply ShowParenSym0 (Apply (Apply (>@#@$) p_0123456789876543210) (FromInteger 10))) (Apply (Apply (.@#@$) (Apply ShowStringSym0 "Y2 ")) (Apply (Apply ShowsPrecSym0 (FromInteger 11)) arg_0123456789876543210))) a_0123456789876543210 + type ShowsPrec_0123456789876543210Sym0 :: forall a. (~>) GHC.Num.Natural.Natural ((~>) (Y a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) data ShowsPrec_0123456789876543210Sym0 :: (~>) GHC.Num.Natural.Natural ((~>) (Y a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) where ShowsPrec_0123456789876543210Sym0KindInference :: SameKind (Apply ShowsPrec_0123456789876543210Sym0 arg) (ShowsPrec_0123456789876543210Sym1 arg) => @@ -95,8 +97,8 @@ Singletons/T371.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings ShowsPrec_0123456789876543210Sym0 where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym0KindInference ()) - type ShowsPrec_0123456789876543210Sym1 :: GHC.Num.Natural.Natural - -> (~>) (Y a) ((~>) GHC.Types.Symbol GHC.Types.Symbol) + type ShowsPrec_0123456789876543210Sym1 :: forall a. GHC.Num.Natural.Natural + -> (~>) (Y a) ((~>) GHC.Types.Symbol GHC.Types.Symbol) data ShowsPrec_0123456789876543210Sym1 (a0123456789876543210 :: GHC.Num.Natural.Natural) :: (~>) (Y a) ((~>) GHC.Types.Symbol GHC.Types.Symbol) where ShowsPrec_0123456789876543210Sym1KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 arg) => @@ -105,8 +107,9 @@ Singletons/T371.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym1 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym1KindInference ()) - type ShowsPrec_0123456789876543210Sym2 :: GHC.Num.Natural.Natural - -> Y a -> (~>) GHC.Types.Symbol GHC.Types.Symbol + type ShowsPrec_0123456789876543210Sym2 :: forall a. GHC.Num.Natural.Natural + -> Y a + -> (~>) GHC.Types.Symbol GHC.Types.Symbol data ShowsPrec_0123456789876543210Sym2 (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: Y a) :: (~>) GHC.Types.Symbol GHC.Types.Symbol where ShowsPrec_0123456789876543210Sym2KindInference :: SameKind (Apply (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) arg) (ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 arg) => @@ -115,8 +118,9 @@ Singletons/T371.hs:(0,0)-(0,0): Splicing declarations instance SuppressUnusedWarnings (ShowsPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) where suppressUnusedWarnings = snd ((,) ShowsPrec_0123456789876543210Sym2KindInference ()) - type ShowsPrec_0123456789876543210Sym3 :: GHC.Num.Natural.Natural - -> Y a -> GHC.Types.Symbol -> GHC.Types.Symbol + type ShowsPrec_0123456789876543210Sym3 :: forall a. GHC.Num.Natural.Natural + -> Y a + -> GHC.Types.Symbol -> GHC.Types.Symbol type family ShowsPrec_0123456789876543210Sym3 @a (a0123456789876543210 :: GHC.Num.Natural.Natural) (a0123456789876543210 :: Y a) (a0123456789876543210 :: GHC.Types.Symbol) :: GHC.Types.Symbol where ShowsPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 a0123456789876543210 = ShowsPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210 instance PShow (Y a) where @@ -146,14 +150,6 @@ Singletons/T371.hs:(0,0)-(0,0): Splicing declarations toSing (Y2 (b :: Demote (X a))) = case toSing b :: SomeSing (X a) of SomeSing c -> SomeSing (SY2 c) instance SShow (Y a) => SShow (X a) where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: X a) - (t3 :: GHC.Types.Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) (X a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SX1 @@ -185,14 +181,6 @@ Singletons/T371.hs:(0,0)-(0,0): Splicing declarations sArg_0123456789876543210))) sA_0123456789876543210 instance SShow (X a) => SShow (Y a) where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: Y a) - (t3 :: GHC.Types.Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) (Y a) ((~>) GHC.Types.Symbol GHC.Types.Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SY1 diff --git a/singletons-base/tests/compile-and-dump/Singletons/T555.golden b/singletons-base/tests/compile-and-dump/Singletons/T555.golden index 922e3c6a..654440b5 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T555.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T555.golden @@ -129,21 +129,11 @@ Singletons/T555.hs:(0,0)-(0,0): Splicing declarations toSing Location = SomeSing SLocation toSing Quaternion = SomeSing SQuaternion instance SEq MyPropKind where - (%==) :: - forall (t1 :: MyPropKind) (t2 :: MyPropKind). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply ((==@#@$) :: TyFun MyPropKind ((~>) MyPropKind Bool) - -> Type) t1) t2) (%==) SLocation SLocation = STrue (%==) SLocation SQuaternion = SFalse (%==) SQuaternion SLocation = SFalse (%==) SQuaternion SQuaternion = STrue instance SOrd MyPropKind where - sCompare :: - forall (t1 :: MyPropKind) (t2 :: MyPropKind). Sing t1 - -> Sing t2 - -> Sing (Apply (Apply (CompareSym0 :: TyFun MyPropKind ((~>) MyPropKind Ordering) - -> Type) t1) t2) sCompare SLocation SLocation = applySing (applySing @@ -159,14 +149,6 @@ Singletons/T555.hs:(0,0)-(0,0): Splicing declarations sCompare SLocation SQuaternion = SLT sCompare SQuaternion SLocation = SGT instance SShow MyPropKind where - sShowsPrec :: - forall (t1 :: GHC.Num.Natural.Natural) - (t2 :: MyPropKind) - (t3 :: Symbol). Sing t1 - -> Sing t2 - -> Sing t3 - -> Sing (Apply (Apply (Apply (ShowsPrecSym0 :: TyFun GHC.Num.Natural.Natural ((~>) MyPropKind ((~>) Symbol Symbol)) - -> Type) t1) t2) t3) sShowsPrec _ SLocation diff --git a/singletons-base/tests/compile-and-dump/Singletons/T581.golden b/singletons-base/tests/compile-and-dump/Singletons/T581.golden new file mode 100644 index 00000000..8f9ce156 --- /dev/null +++ b/singletons-base/tests/compile-and-dump/Singletons/T581.golden @@ -0,0 +1,392 @@ +Singletons/T581.hs:(0,0)-(0,0): Splicing declarations + singletons + [d| class C1 a where + m1 :: forall b. a -> Maybe (a, b) + m1 _ = Nothing :: Maybe (a, b) + class C2 a where + m2 :: b -> Maybe a + m2 _ = Nothing :: Maybe a + class C3 a where + m3 :: forall b. a -> b -> (a, b) + m3 x y = (x, y) :: (a, b) + + instance C1 [a] where + m1 :: forall b. [a] -> Maybe ([a], b) + m1 _ = Nothing :: Maybe ([a], b) + instance C2 (Maybe a) where + m2 _ = Nothing :: Maybe (Maybe a) + instance C2 [a] where + m2 :: b -> Maybe [a] + m2 _ = Nothing :: Maybe [a] + instance C3 [a] where + m3 x y = (fmap (\ xx -> (xx :: a)) x, y) + instance C3 (Maybe a) where + m3 :: Maybe a -> b -> (Maybe a, b) + m3 x y = (fmap (\ xx -> (xx :: a)) x, y) |] + ======> + class C1 a where + m1 :: forall b. a -> Maybe (a, b) + m1 _ = Nothing :: Maybe (a, b) + instance C1 [a] where + m1 :: forall b. [a] -> Maybe ([a], b) + m1 _ = Nothing :: Maybe ([a], b) + class C2 a where + m2 :: b -> Maybe a + m2 _ = Nothing :: Maybe a + instance C2 [a] where + m2 :: b -> Maybe [a] + m2 _ = Nothing :: Maybe [a] + instance C2 (Maybe a) where + m2 _ = Nothing :: Maybe (Maybe a) + class C3 a where + m3 :: forall b. a -> b -> (a, b) + m3 x y = (x, y) :: (a, b) + instance C3 (Maybe a) where + m3 :: Maybe a -> b -> (Maybe a, b) + m3 x y = (fmap (\ xx -> xx :: a) x, y) + instance C3 [a] where + m3 x y = (fmap (\ xx -> xx :: a) x, y) + type M1Sym0 :: forall a b. (~>) a (Maybe (a, b)) + data M1Sym0 :: (~>) a (Maybe (a, b)) + where + M1Sym0KindInference :: SameKind (Apply M1Sym0 arg) (M1Sym1 arg) => + M1Sym0 a0123456789876543210 + type instance Apply M1Sym0 a0123456789876543210 = M1 a0123456789876543210 + instance SuppressUnusedWarnings M1Sym0 where + suppressUnusedWarnings = snd ((,) M1Sym0KindInference ()) + type M1Sym1 :: forall a b. a -> Maybe (a, b) + type family M1Sym1 @a @b (a0123456789876543210 :: a) :: Maybe (a, + b) where + M1Sym1 a0123456789876543210 = M1 a0123456789876543210 + type M1_0123456789876543210 :: forall a b. a -> Maybe (a, b) + type family M1_0123456789876543210 @a @b (a :: a) :: Maybe (a, + b) where + M1_0123456789876543210 @a @b (_ :: a) = NothingSym0 :: Maybe (a, b) + type M1_0123456789876543210Sym0 :: forall a b. (~>) a (Maybe (a, + b)) + data M1_0123456789876543210Sym0 :: (~>) a (Maybe (a, b)) + where + M1_0123456789876543210Sym0KindInference :: SameKind (Apply M1_0123456789876543210Sym0 arg) (M1_0123456789876543210Sym1 arg) => + M1_0123456789876543210Sym0 a0123456789876543210 + type instance Apply M1_0123456789876543210Sym0 a0123456789876543210 = M1_0123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings M1_0123456789876543210Sym0 where + suppressUnusedWarnings + = snd ((,) M1_0123456789876543210Sym0KindInference ()) + type M1_0123456789876543210Sym1 :: forall a b. a -> Maybe (a, b) + type family M1_0123456789876543210Sym1 @a @b (a0123456789876543210 :: a) :: Maybe (a, + b) where + M1_0123456789876543210Sym1 a0123456789876543210 = M1_0123456789876543210 a0123456789876543210 + class PC1 a where + type family M1 (arg :: a) :: Maybe (a, b) + type M1 a = Apply M1_0123456789876543210Sym0 a + type M2Sym0 :: forall b a. (~>) b (Maybe a) + data M2Sym0 :: (~>) b (Maybe a) + where + M2Sym0KindInference :: SameKind (Apply M2Sym0 arg) (M2Sym1 arg) => + M2Sym0 a0123456789876543210 + type instance Apply M2Sym0 a0123456789876543210 = M2 a0123456789876543210 + instance SuppressUnusedWarnings M2Sym0 where + suppressUnusedWarnings = snd ((,) M2Sym0KindInference ()) + type M2Sym1 :: forall b a. b -> Maybe a + type family M2Sym1 @b @a (a0123456789876543210 :: b) :: Maybe a where + M2Sym1 a0123456789876543210 = M2 a0123456789876543210 + type M2_0123456789876543210 :: forall b a. b -> Maybe a + type family M2_0123456789876543210 @b @a (a :: b) :: Maybe a where + M2_0123456789876543210 @b @a (_ :: b) = NothingSym0 :: Maybe a + type M2_0123456789876543210Sym0 :: forall b a. (~>) b (Maybe a) + data M2_0123456789876543210Sym0 :: (~>) b (Maybe a) + where + M2_0123456789876543210Sym0KindInference :: SameKind (Apply M2_0123456789876543210Sym0 arg) (M2_0123456789876543210Sym1 arg) => + M2_0123456789876543210Sym0 a0123456789876543210 + type instance Apply M2_0123456789876543210Sym0 a0123456789876543210 = M2_0123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings M2_0123456789876543210Sym0 where + suppressUnusedWarnings + = snd ((,) M2_0123456789876543210Sym0KindInference ()) + type M2_0123456789876543210Sym1 :: forall b a. b -> Maybe a + type family M2_0123456789876543210Sym1 @b @a (a0123456789876543210 :: b) :: Maybe a where + M2_0123456789876543210Sym1 a0123456789876543210 = M2_0123456789876543210 a0123456789876543210 + class PC2 a where + type family M2 (arg :: b) :: Maybe a + type M2 a = Apply M2_0123456789876543210Sym0 a + type M3Sym0 :: forall a b. (~>) a ((~>) b (a, b)) + data M3Sym0 :: (~>) a ((~>) b (a, b)) + where + M3Sym0KindInference :: SameKind (Apply M3Sym0 arg) (M3Sym1 arg) => + M3Sym0 a0123456789876543210 + type instance Apply M3Sym0 a0123456789876543210 = M3Sym1 a0123456789876543210 + instance SuppressUnusedWarnings M3Sym0 where + suppressUnusedWarnings = snd ((,) M3Sym0KindInference ()) + type M3Sym1 :: forall a b. a -> (~>) b (a, b) + data M3Sym1 (a0123456789876543210 :: a) :: (~>) b (a, b) + where + M3Sym1KindInference :: SameKind (Apply (M3Sym1 a0123456789876543210) arg) (M3Sym2 a0123456789876543210 arg) => + M3Sym1 a0123456789876543210 a0123456789876543210 + type instance Apply (M3Sym1 a0123456789876543210) a0123456789876543210 = M3 a0123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings (M3Sym1 a0123456789876543210) where + suppressUnusedWarnings = snd ((,) M3Sym1KindInference ()) + type M3Sym2 :: forall a b. a -> b -> (a, b) + type family M3Sym2 @a @b (a0123456789876543210 :: a) (a0123456789876543210 :: b) :: (a, + b) where + M3Sym2 a0123456789876543210 a0123456789876543210 = M3 a0123456789876543210 a0123456789876543210 + type M3_0123456789876543210 :: forall a b. a -> b -> (a, b) + type family M3_0123456789876543210 @a @b (a :: a) (a :: b) :: (a, + b) where + M3_0123456789876543210 @a @b (x :: a) (y :: b) = Apply (Apply Tuple2Sym0 x) y :: (a, + b) + type M3_0123456789876543210Sym0 :: forall a b. (~>) a ((~>) b (a, + b)) + data M3_0123456789876543210Sym0 :: (~>) a ((~>) b (a, b)) + where + M3_0123456789876543210Sym0KindInference :: SameKind (Apply M3_0123456789876543210Sym0 arg) (M3_0123456789876543210Sym1 arg) => + M3_0123456789876543210Sym0 a0123456789876543210 + type instance Apply M3_0123456789876543210Sym0 a0123456789876543210 = M3_0123456789876543210Sym1 a0123456789876543210 + instance SuppressUnusedWarnings M3_0123456789876543210Sym0 where + suppressUnusedWarnings + = snd ((,) M3_0123456789876543210Sym0KindInference ()) + type M3_0123456789876543210Sym1 :: forall a b. a -> (~>) b (a, b) + data M3_0123456789876543210Sym1 (a0123456789876543210 :: a) :: (~>) b (a, + b) + where + M3_0123456789876543210Sym1KindInference :: SameKind (Apply (M3_0123456789876543210Sym1 a0123456789876543210) arg) (M3_0123456789876543210Sym2 a0123456789876543210 arg) => + M3_0123456789876543210Sym1 a0123456789876543210 a0123456789876543210 + type instance Apply (M3_0123456789876543210Sym1 a0123456789876543210) a0123456789876543210 = M3_0123456789876543210 a0123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings (M3_0123456789876543210Sym1 a0123456789876543210) where + suppressUnusedWarnings + = snd ((,) M3_0123456789876543210Sym1KindInference ()) + type M3_0123456789876543210Sym2 :: forall a b. a -> b -> (a, b) + type family M3_0123456789876543210Sym2 @a @b (a0123456789876543210 :: a) (a0123456789876543210 :: b) :: (a, + b) where + M3_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = M3_0123456789876543210 a0123456789876543210 a0123456789876543210 + class PC3 a where + type family M3 (arg :: a) (arg :: b) :: (a, b) + type M3 a a = Apply (Apply M3_0123456789876543210Sym0 a) a + type M1_0123456789876543210 :: forall a b. [a] -> Maybe ([a], b) + type family M1_0123456789876543210 @a @b (a :: [a]) :: Maybe ([a], + b) where + M1_0123456789876543210 @a @b (_ :: [a]) = NothingSym0 :: Maybe ([a], + b) + type M1_0123456789876543210Sym0 :: forall a + b. (~>) [a] (Maybe ([a], b)) + data M1_0123456789876543210Sym0 :: (~>) [a] (Maybe ([a], b)) + where + M1_0123456789876543210Sym0KindInference :: SameKind (Apply M1_0123456789876543210Sym0 arg) (M1_0123456789876543210Sym1 arg) => + M1_0123456789876543210Sym0 a0123456789876543210 + type instance Apply M1_0123456789876543210Sym0 a0123456789876543210 = M1_0123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings M1_0123456789876543210Sym0 where + suppressUnusedWarnings + = snd ((,) M1_0123456789876543210Sym0KindInference ()) + type M1_0123456789876543210Sym1 :: forall a b. [a] + -> Maybe ([a], b) + type family M1_0123456789876543210Sym1 @a @b (a0123456789876543210 :: [a]) :: Maybe ([a], + b) where + M1_0123456789876543210Sym1 a0123456789876543210 = M1_0123456789876543210 a0123456789876543210 + instance PC1 [a] where + type M1 a = Apply M1_0123456789876543210Sym0 a + type M2_0123456789876543210 :: forall b a. b -> Maybe [a] + type family M2_0123456789876543210 @b @a (a :: b) :: Maybe [a] where + M2_0123456789876543210 @b @a (_ :: b) = NothingSym0 :: Maybe [a] + type M2_0123456789876543210Sym0 :: forall b a. (~>) b (Maybe [a]) + data M2_0123456789876543210Sym0 :: (~>) b (Maybe [a]) + where + M2_0123456789876543210Sym0KindInference :: SameKind (Apply M2_0123456789876543210Sym0 arg) (M2_0123456789876543210Sym1 arg) => + M2_0123456789876543210Sym0 a0123456789876543210 + type instance Apply M2_0123456789876543210Sym0 a0123456789876543210 = M2_0123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings M2_0123456789876543210Sym0 where + suppressUnusedWarnings + = snd ((,) M2_0123456789876543210Sym0KindInference ()) + type M2_0123456789876543210Sym1 :: forall b a. b -> Maybe [a] + type family M2_0123456789876543210Sym1 @b @a (a0123456789876543210 :: b) :: Maybe [a] where + M2_0123456789876543210Sym1 a0123456789876543210 = M2_0123456789876543210 a0123456789876543210 + instance PC2 [a] where + type M2 a = Apply M2_0123456789876543210Sym0 a + type M2_0123456789876543210 :: forall b a. b -> Maybe (Maybe a) + type family M2_0123456789876543210 @b @a (a :: b) :: Maybe (Maybe a) where + M2_0123456789876543210 @b @a (_ :: b) = NothingSym0 :: Maybe (Maybe a) + type M2_0123456789876543210Sym0 :: forall b + a. (~>) b (Maybe (Maybe a)) + data M2_0123456789876543210Sym0 :: (~>) b (Maybe (Maybe a)) + where + M2_0123456789876543210Sym0KindInference :: SameKind (Apply M2_0123456789876543210Sym0 arg) (M2_0123456789876543210Sym1 arg) => + M2_0123456789876543210Sym0 a0123456789876543210 + type instance Apply M2_0123456789876543210Sym0 a0123456789876543210 = M2_0123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings M2_0123456789876543210Sym0 where + suppressUnusedWarnings + = snd ((,) M2_0123456789876543210Sym0KindInference ()) + type M2_0123456789876543210Sym1 :: forall b a. b -> Maybe (Maybe a) + type family M2_0123456789876543210Sym1 @b @a (a0123456789876543210 :: b) :: Maybe (Maybe a) where + M2_0123456789876543210Sym1 a0123456789876543210 = M2_0123456789876543210 a0123456789876543210 + instance PC2 (Maybe a) where + type M2 a = Apply M2_0123456789876543210Sym0 a + type family Lambda_0123456789876543210 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx where + Lambda_0123456789876543210 a x y xx = xx :: a + data Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 + where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 y0123456789876543210) arg) (Lambda_0123456789876543210Sym1 a0123456789876543210 x0123456789876543210 y0123456789876543210 arg) => + Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 y0123456789876543210) xx0123456789876543210 = Lambda_0123456789876543210 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 y0123456789876543210) where + suppressUnusedWarnings + = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) + type family Lambda_0123456789876543210Sym1 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 where + Lambda_0123456789876543210Sym1 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 = Lambda_0123456789876543210 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 + type M3_0123456789876543210 :: forall a b. Maybe a + -> b -> (Maybe a, b) + type family M3_0123456789876543210 @a @b (a :: Maybe a) (a :: b) :: (Maybe a, + b) where + M3_0123456789876543210 @a @b (x :: Maybe a) (y :: b) = Apply (Apply Tuple2Sym0 (Apply (Apply FmapSym0 (Lambda_0123456789876543210Sym0 a x y)) x)) y + type M3_0123456789876543210Sym0 :: forall a + b. (~>) (Maybe a) ((~>) b (Maybe a, b)) + data M3_0123456789876543210Sym0 :: (~>) (Maybe a) ((~>) b (Maybe a, + b)) + where + M3_0123456789876543210Sym0KindInference :: SameKind (Apply M3_0123456789876543210Sym0 arg) (M3_0123456789876543210Sym1 arg) => + M3_0123456789876543210Sym0 a0123456789876543210 + type instance Apply M3_0123456789876543210Sym0 a0123456789876543210 = M3_0123456789876543210Sym1 a0123456789876543210 + instance SuppressUnusedWarnings M3_0123456789876543210Sym0 where + suppressUnusedWarnings + = snd ((,) M3_0123456789876543210Sym0KindInference ()) + type M3_0123456789876543210Sym1 :: forall a b. Maybe a + -> (~>) b (Maybe a, b) + data M3_0123456789876543210Sym1 (a0123456789876543210 :: Maybe a) :: (~>) b (Maybe a, + b) + where + M3_0123456789876543210Sym1KindInference :: SameKind (Apply (M3_0123456789876543210Sym1 a0123456789876543210) arg) (M3_0123456789876543210Sym2 a0123456789876543210 arg) => + M3_0123456789876543210Sym1 a0123456789876543210 a0123456789876543210 + type instance Apply (M3_0123456789876543210Sym1 a0123456789876543210) a0123456789876543210 = M3_0123456789876543210 a0123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings (M3_0123456789876543210Sym1 a0123456789876543210) where + suppressUnusedWarnings + = snd ((,) M3_0123456789876543210Sym1KindInference ()) + type M3_0123456789876543210Sym2 :: forall a b. Maybe a + -> b -> (Maybe a, b) + type family M3_0123456789876543210Sym2 @a @b (a0123456789876543210 :: Maybe a) (a0123456789876543210 :: b) :: (Maybe a, + b) where + M3_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = M3_0123456789876543210 a0123456789876543210 a0123456789876543210 + instance PC3 (Maybe a) where + type M3 a a = Apply (Apply M3_0123456789876543210Sym0 a) a + type family Lambda_0123456789876543210 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx where + Lambda_0123456789876543210 a x y xx = xx :: a + data Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 + where + Lambda_0123456789876543210Sym0KindInference :: SameKind (Apply (Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 y0123456789876543210) arg) (Lambda_0123456789876543210Sym1 a0123456789876543210 x0123456789876543210 y0123456789876543210 arg) => + Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 + type instance Apply (Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 y0123456789876543210) xx0123456789876543210 = Lambda_0123456789876543210 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 + instance SuppressUnusedWarnings (Lambda_0123456789876543210Sym0 a0123456789876543210 x0123456789876543210 y0123456789876543210) where + suppressUnusedWarnings + = snd ((,) Lambda_0123456789876543210Sym0KindInference ()) + type family Lambda_0123456789876543210Sym1 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 where + Lambda_0123456789876543210Sym1 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 = Lambda_0123456789876543210 a0123456789876543210 x0123456789876543210 y0123456789876543210 xx0123456789876543210 + type M3_0123456789876543210 :: forall a b. [a] -> b -> ([a], b) + type family M3_0123456789876543210 @a @b (a :: [a]) (a :: b) :: ([a], + b) where + M3_0123456789876543210 @a @b (x :: [a]) (y :: b) = Apply (Apply Tuple2Sym0 (Apply (Apply FmapSym0 (Lambda_0123456789876543210Sym0 a x y)) x)) y + type M3_0123456789876543210Sym0 :: forall a + b. (~>) [a] ((~>) b ([a], b)) + data M3_0123456789876543210Sym0 :: (~>) [a] ((~>) b ([a], b)) + where + M3_0123456789876543210Sym0KindInference :: SameKind (Apply M3_0123456789876543210Sym0 arg) (M3_0123456789876543210Sym1 arg) => + M3_0123456789876543210Sym0 a0123456789876543210 + type instance Apply M3_0123456789876543210Sym0 a0123456789876543210 = M3_0123456789876543210Sym1 a0123456789876543210 + instance SuppressUnusedWarnings M3_0123456789876543210Sym0 where + suppressUnusedWarnings + = snd ((,) M3_0123456789876543210Sym0KindInference ()) + type M3_0123456789876543210Sym1 :: forall a b. [a] + -> (~>) b ([a], b) + data M3_0123456789876543210Sym1 (a0123456789876543210 :: [a]) :: (~>) b ([a], + b) + where + M3_0123456789876543210Sym1KindInference :: SameKind (Apply (M3_0123456789876543210Sym1 a0123456789876543210) arg) (M3_0123456789876543210Sym2 a0123456789876543210 arg) => + M3_0123456789876543210Sym1 a0123456789876543210 a0123456789876543210 + type instance Apply (M3_0123456789876543210Sym1 a0123456789876543210) a0123456789876543210 = M3_0123456789876543210 a0123456789876543210 a0123456789876543210 + instance SuppressUnusedWarnings (M3_0123456789876543210Sym1 a0123456789876543210) where + suppressUnusedWarnings + = snd ((,) M3_0123456789876543210Sym1KindInference ()) + type M3_0123456789876543210Sym2 :: forall a b. [a] -> b -> ([a], b) + type family M3_0123456789876543210Sym2 @a @b (a0123456789876543210 :: [a]) (a0123456789876543210 :: b) :: ([a], + b) where + M3_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 = M3_0123456789876543210 a0123456789876543210 a0123456789876543210 + instance PC3 [a] where + type M3 a a = Apply (Apply M3_0123456789876543210Sym0 a) a + class SC1 a where + sM1 :: + forall b (t :: a). Sing t -> Sing (Apply M1Sym0 t :: Maybe (a, b)) + default sM1 :: + forall b (t :: a). ((Apply M1Sym0 t :: Maybe (a, b)) + ~ Apply M1_0123456789876543210Sym0 t) => + Sing t -> Sing (Apply M1Sym0 t :: Maybe (a, b)) + sM1 _ = SNothing :: Sing (NothingSym0 :: Maybe (a, b)) + class SC2 a where + sM2 :: + (forall (t :: b). + Sing t -> Sing (Apply M2Sym0 t :: Maybe a) :: Type) + default sM2 :: + (forall (t :: b). + ((Apply M2Sym0 t :: Maybe a) + ~ Apply M2_0123456789876543210Sym0 t) => + Sing t -> Sing (Apply M2Sym0 t :: Maybe a) :: Type) + sM2 _ = SNothing :: Sing (NothingSym0 :: Maybe a) + class SC3 a where + sM3 :: + forall b (t :: a) (t :: b). Sing t + -> Sing t -> Sing (Apply (Apply M3Sym0 t) t :: (a, b)) + default sM3 :: + forall b (t :: a) (t :: b). ((Apply (Apply M3Sym0 t) t :: (a, b)) + ~ Apply (Apply M3_0123456789876543210Sym0 t) t) => + Sing t + -> Sing t -> Sing (Apply (Apply M3Sym0 t) t :: (a, b)) + sM3 (sX :: Sing x) (sY :: Sing y) + = applySing (applySing (singFun2 @Tuple2Sym0 STuple2) sX) sY :: + Sing (Apply (Apply Tuple2Sym0 x) y :: (a, b)) + instance SC1 [a] where + sM1 :: + forall b (t :: [a]). Sing t + -> Sing (Apply M1Sym0 t :: Maybe ([a], b)) + sM1 _ = SNothing :: Sing (NothingSym0 :: Maybe ([a], b)) + instance SC2 [a] where + sM2 :: + (forall (t :: b). + Sing t -> Sing (Apply M2Sym0 t :: Maybe [a]) :: Type) + sM2 _ = SNothing :: Sing (NothingSym0 :: Maybe [a]) + instance SC2 (Maybe a) where + sM2 _ = SNothing :: Sing (NothingSym0 :: Maybe (Maybe a)) + instance SC3 (Maybe a) where + sM3 :: + (forall (t :: Maybe a) (t :: b). + Sing t + -> Sing t + -> Sing (Apply (Apply M3Sym0 t) t :: (Maybe a, b)) :: Type) + sM3 (sX :: Sing x) (sY :: Sing y) + = applySing + (applySing + (singFun2 @Tuple2Sym0 STuple2) + (applySing + (applySing + (singFun2 @FmapSym0 sFmap) + (singFun1 + @(Lambda_0123456789876543210Sym0 a x y) + (\ sXx -> case sXx of (_ :: Sing xx) -> sXx :: Sing (xx :: a)))) + sX)) + sY + instance SC3 [a] where + sM3 (sX :: Sing x) (sY :: Sing y) + = applySing + (applySing + (singFun2 @Tuple2Sym0 STuple2) + (applySing + (applySing + (singFun2 @FmapSym0 sFmap) + (singFun1 + @(Lambda_0123456789876543210Sym0 a x y) + (\ sXx -> case sXx of (_ :: Sing xx) -> sXx :: Sing (xx :: a)))) + sX)) + sY + instance SC1 a => SingI (M1Sym0 :: (~>) a (Maybe (a, b))) where + sing = singFun1 @M1Sym0 sM1 + instance SC2 a => SingI (M2Sym0 :: (~>) b (Maybe a)) where + sing = singFun1 @M2Sym0 sM2 + instance SC3 a => SingI (M3Sym0 :: (~>) a ((~>) b (a, b))) where + sing = singFun2 @M3Sym0 sM3 + instance (SC3 a, SingI d) => + SingI (M3Sym1 (d :: a) :: (~>) b (a, b)) where + sing = singFun1 @(M3Sym1 (d :: a)) (sM3 (sing @d)) + instance SC3 a => SingI1 (M3Sym1 :: a -> (~>) b (a, b)) where + liftSing (s :: Sing (d :: a)) = singFun1 @(M3Sym1 (d :: a)) (sM3 s) diff --git a/singletons-base/tests/compile-and-dump/Singletons/T581.hs b/singletons-base/tests/compile-and-dump/Singletons/T581.hs new file mode 100644 index 00000000..6f54a829 --- /dev/null +++ b/singletons-base/tests/compile-and-dump/Singletons/T581.hs @@ -0,0 +1,36 @@ +module T581 where + +import Data.Singletons.Base.TH +import Prelude.Singletons + +$(singletons + [d| class C1 a where + m1 :: forall b. a -> Maybe (a, b) + m1 _ = Nothing :: Maybe (a, b) + + instance C1 [a] where + m1 :: forall b. [a] -> Maybe ([a], b) + m1 _ = Nothing :: Maybe ([a], b) + + class C2 a where + m2 :: b -> Maybe a + m2 _ = Nothing :: Maybe a + + instance C2 [a] where + m2 :: b -> Maybe [a] + m2 _ = Nothing :: Maybe [a] + + instance C2 (Maybe a) where + m2 _ = Nothing :: Maybe (Maybe a) + + class C3 a where + m3 :: forall b. a -> b -> (a, b) + m3 x y = (x, y) :: (a, b) + + instance C3 (Maybe a) where + m3 :: Maybe a -> b -> (Maybe a, b) + m3 x y = (fmap (\xx -> (xx :: a)) x, y) + + instance C3 [a] where + m3 x y = (fmap (\xx -> (xx :: a)) x, y) + |]) diff --git a/singletons-base/tests/compile-and-dump/Singletons/T89.golden b/singletons-base/tests/compile-and-dump/Singletons/T89.golden index a9c252ff..fc8815cf 100644 --- a/singletons-base/tests/compile-and-dump/Singletons/T89.golden +++ b/singletons-base/tests/compile-and-dump/Singletons/T89.golden @@ -55,14 +55,6 @@ Singletons/T89.hs:0:0:: Splicing declarations fromSing SFoo = Foo toSing Foo = SomeSing SFoo instance SEnum Foo where - sToEnum :: - forall (t :: GHC.Num.Natural.Natural). Sing t - -> Sing (Apply (Data.Singletons.Base.Enum.ToEnumSym0 :: TyFun GHC.Num.Natural.Natural Foo - -> Type) t) - sFromEnum :: - forall (t :: Foo). Sing t - -> Sing (Apply (Data.Singletons.Base.Enum.FromEnumSym0 :: TyFun Foo GHC.Num.Natural.Natural - -> Type) t) sToEnum (sN :: Sing n) = id @(Sing (Case_0123456789876543210 n (Apply (Apply (==@#@$) n) (FromInteger 0)))) diff --git a/singletons-th/CHANGES.md b/singletons-th/CHANGES.md index 7346de83..29cb7000 100644 --- a/singletons-th/CHANGES.md +++ b/singletons-th/CHANGES.md @@ -1,6 +1,11 @@ Changelog for the `singletons-th` project ========================================= +next [????.??.??] +----------------- +* Add support for promoting and singling type variables that scope over the + bodies of class method defaults and instance methods. + 3.4 [2024.05.12] ---------------- * Require building with GHC 9.10. diff --git a/singletons-th/src/Data/Singletons/TH/Promote.hs b/singletons-th/src/Data/Singletons/TH/Promote.hs index d991fc46..c25659dd 100644 --- a/singletons-th/src/Data/Singletons/TH/Promote.hs +++ b/singletons-th/src/Data/Singletons/TH/Promote.hs @@ -15,6 +15,7 @@ import Language.Haskell.TH.Desugar import qualified Language.Haskell.TH.Desugar.OMap.Strict as OMap import Language.Haskell.TH.Desugar.OMap.Strict (OMap) import qualified Language.Haskell.TH.Desugar.OSet as OSet +import Language.Haskell.TH.Desugar.OSet (OSet) import Data.Singletons.TH.Deriving.Bounded import Data.Singletons.TH.Deriving.Enum import Data.Singletons.TH.Deriving.Eq @@ -256,7 +257,7 @@ promoteDataDec (DataDecl _ _ _ ctors) = do promoteClassDec :: UClassDecl -> PrM AClassDecl promoteClassDec decl@(ClassDecl { cd_name = cls_name - , cd_tvbs = tvbs + , cd_tvbs = cls_tvbs , cd_fds = fundeps , cd_atfs = atfs , cd_lde = lde@LetDecEnv @@ -269,18 +270,19 @@ promoteClassDec decl@(ClassDecl { cd_name = cls_name meth_names = map fst meth_sigs_list defaults_list = OMap.assocs defaults defaults_names = map fst defaults_list + cls_tvb_names = map extractTvbName cls_tvbs mb_cls_sak <- dsReifyType cls_name sig_decs <- mapM (uncurry promote_sig) meth_sigs_list (default_decs, ann_rhss, prom_rhss) - <- mapAndUnzip3M (promoteMethod DefaultMethods meth_sigs) defaults_list - defunAssociatedTypeFamilies tvbs atfs + <- mapAndUnzip3M (promoteMethod DefaultMethods meth_sigs cls_tvb_names) defaults_list + defunAssociatedTypeFamilies cls_tvbs atfs infix_decls' <- mapMaybeM (uncurry (promoteInfixDecl Nothing)) $ OMap.assocs infix_decls cls_infix_decls <- promoteReifiedInfixDecls $ cls_name:meth_names -- no need to do anything to the fundeps. They work as is! - let pro_cls_dec = DClassD [] pClsName tvbs fundeps + let pro_cls_dec = DClassD [] pClsName cls_tvbs fundeps (sig_decs ++ default_decs ++ infix_decls') mb_pro_cls_sak = fmap (DKiSigD pClsName) mb_cls_sak emitDecs $ maybeToList mb_pro_cls_sak ++ pro_cls_dec:cls_infix_decls @@ -376,8 +378,9 @@ promoteInstanceDec orig_meth_sigs cls_tvbs_map cls_tvb_names = map extractTvbName cls_tvbs subst = Map.fromList $ zip cls_tvb_names inst_kis meth_impl = InstanceMethods inst_sigs subst + inst_ki_fvs = map extractTvbName $ toposortTyVarsOf inst_kis (meths', ann_rhss, _) - <- mapAndUnzip3M (promoteMethod meth_impl orig_meth_sigs) meths + <- mapAndUnzip3M (promoteMethod meth_impl orig_meth_sigs inst_ki_fvs) meths emitDecs [DInstanceD Nothing Nothing [] (foldType (DConT pClsName) inst_kis) meths'] return (decl { id_meths = zip (map fst meths) ann_rhss }) @@ -459,12 +462,28 @@ data MethodSort promoteMethod :: MethodSort -> OMap Name DType -- method types + -> [Name] -- The names of the type variables bound by the class + -- header (e.g., the @a@ in @class C a where ...@). -> (Name, ULetDecRHS) -> PrM (DDec, ALetDecRHS, DType) -- returns (type instance, ALetDecRHS, promoted RHS) -promoteMethod meth_sort orig_sigs_map (meth_name, meth_rhs) = do +promoteMethod meth_sort orig_sigs_map cls_tvb_names (meth_name, meth_rhs) = do opts <- getOptions - (meth_arg_kis, meth_res_ki) <- promote_meth_ty + (meth_tvbs, meth_arg_kis, meth_res_ki) <- promote_meth_ty + -- If ScopedTypeVariables is enabled, bring type variables into scope over the + -- RHS. These type variables can come from the class/instance header, the + -- method type signature/instance signature, or both, depending on how the + -- class or instance declaration is written. See + -- Note [Scoped type variables and class methods] in D.S.TH.Promote.Monad. + -- See also (Wrinkle: Partial scoping) from that Note for a scenario in which + -- we bring class/instance header type variables into scope but /not/ + -- type variables from the class method/instance signature. + scoped_tvs_ext <- qIsExtEnabled LangExt.ScopedTypeVariables + let meth_scoped_tvs + | scoped_tvs_ext + = OSet.fromList (cls_tvb_names ++ map extractTvbName meth_tvbs) + | otherwise + = OSet.empty meth_arg_tvs <- replicateM (length meth_arg_kis) (qNewName "a") let proName = promotedTopLevelValueName opts meth_name helperNameBase = case nameBase proName of @@ -487,7 +506,7 @@ promoteMethod meth_sort orig_sigs_map (meth_name, meth_rhs) = do helperName <- newUniqueName helperNameBase let helperDefunName = defunctionalizedName0 opts helperName (pro_decs, defun_decs, ann_rhs) - <- promoteLetDecRHS (ClassMethodRHS meth_arg_kis meth_res_ki) + <- promoteLetDecRHS (ClassMethodRHS meth_scoped_tvs meth_arg_kis meth_res_ki) OMap.empty OMap.empty Nothing helperName meth_rhs emitDecs (pro_decs ++ defun_decs) @@ -504,7 +523,19 @@ promoteMethod meth_sort orig_sigs_map (meth_name, meth_rhs) = do -- the types in the instance head. (e.g., if you have `class C a` and -- `instance C T`, then the substitution [a |-> T] must be applied to the -- original method's type.) - promote_meth_ty :: PrM ([DKind], DKind) + -- + -- This returns three things in a tuple: + -- + -- * The list of scoped type variables from the class method signature or + -- instance signature. If an instance method lacks an instance signature, + -- this will be an empty list. These type variables will be brought into + -- scope over the RHS of the method: see Note [Scoped type variables and + -- class methods] in D.S.TH.Promote.Monad. + -- + -- * The promoted argument kinds. + -- + -- * The promoted result kind. + promote_meth_ty :: PrM ([DTyVarBndrSpec], [DKind], DKind) promote_meth_ty = case meth_sort of DefaultMethods -> @@ -518,28 +549,29 @@ promoteMethod meth_sort orig_sigs_map (meth_name, meth_rhs) = do -- We have an InstanceSig. These are easy: we can just use the -- instance signature's type directly, and no substitution for -- class variables is required. - (_tvbs, arg_kis, res_ki) <- promoteUnraveled ty - pure (arg_kis, res_ki) + promoteUnraveled ty Nothing -> do -- We don't have an InstanceSig, so we must compute the kind to use -- ourselves. - (arg_kis, res_ki) <- lookup_meth_ty + (_, arg_kis, res_ki) <- lookup_meth_ty -- Substitute for the class variables in the method's type. -- See Note [Promoted class method kinds] let arg_kis' = map (substKind cls_subst) arg_kis res_ki' = substKind cls_subst res_ki - pure (arg_kis', res_ki') + -- If there is no instance signature, then there are no additional + -- type variables to bring into scope, so return an empty list of + -- scoped type variables. + pure ([], arg_kis', res_ki') -- Attempt to look up a class method's original type. - lookup_meth_ty :: PrM ([DKind], DKind) + lookup_meth_ty :: PrM ([DTyVarBndrSpec], [DKind], DKind) lookup_meth_ty = do opts <- getOptions let proName = promotedTopLevelValueName opts meth_name case OMap.lookup meth_name orig_sigs_map of Just ty -> do -- The type of the method is in scope, so promote that. - (_tvbs, arg_kis, res_ki) <- promoteUnraveled ty - pure (arg_kis, res_ki) + promoteUnraveled ty Nothing -> do -- If the type of the method is not in scope, the only other option -- is to try reifying the promoted method name. @@ -549,7 +581,10 @@ promoteMethod meth_sort orig_sigs_map (meth_name, meth_rhs) = do Just (DTyConI (DOpenTypeFamilyD (DTypeFamilyHead _ tvbs mb_res_ki _)) _) -> let arg_kis = map (defaultMaybeToTypeKind . extractTvbKind) tvbs res_ki = defaultMaybeToTypeKind (resultSigToMaybeKind mb_res_ki) - in pure (arg_kis, res_ki) + -- If there is no instance signature, then there are no + -- additional type variables to bring into scope, so return an + -- empty list of scoped type variables. + in pure ([], arg_kis, res_ki) _ -> fail $ "Cannot find type annotation for " ++ show proName {- @@ -688,8 +723,12 @@ data LetDecRHSSort -- The right-hand side of a class method (either a default method or a -- method in an instance declaration). | ClassMethodRHS - [DKind] DKind - -- The RHS's promoted argument and result types. Needed to fix #136. + (OSet Name) -- The scoped type variables to bring into scope over + -- the RHS of the class method. See + -- Note [Scoped type variables and class methods] + -- in D.S.TH.Promote.Monad. + [DKind] -- The RHS's promoted argument kinds. Needed to fix #136. + DKind -- The RHS's promoted result kind. Needed to fix #136. deriving Show -- This function is used both to promote class method defaults and normal @@ -772,9 +811,8 @@ promoteLetDecRHS rhs_sort type_env fix_env mb_let_uniq name let_dec_rhs = do , mk_tf_head arg_tvbs DNoSig ) -- 2. We have some kind information in the form of a LetDecRHSKindInfo. - Just (LDRKI m_sak tvbs argKs resK) -> - let arg_tvbs = zipWith (`DKindedTV` BndrReq) tyvarNames argKs - lde_kvs_to_bind' = OSet.fromList (map extractTvbName tvbs) in + Just (LDRKI m_sak lde_kvs_to_bind' tvbs argKs resK) -> + let arg_tvbs = zipWith (`DKindedTV` BndrReq) tyvarNames argKs in case m_sak of -- 2(a). We do not have a standalone kind signature. Nothing -> @@ -832,15 +870,19 @@ promoteLetDecRHS rhs_sort type_env fix_env mb_let_uniq name let_dec_rhs = do -- will default to the earlier Int argument. promote_let_dec_ty all_locals default_num_args = case rhs_sort of - ClassMethodRHS arg_kis res_ki - -> -- For class method RHS helper functions, don't bother quantifying - -- any type variables in their SAKS. We could certainly try, but - -- given that these functions are only used internally, there's no - -- point in trying to get the order of type variables correct, - -- since we don't apply these functions with visible kind - -- applications. - let sak = ravelVanillaDType [] [] arg_kis res_ki in - return (Just (LDRKI (Just sak) [] arg_kis res_ki), length arg_kis) + ClassMethodRHS scoped_tvs arg_kis res_ki + -> -- Class method RHS helper functions are only used internally, so + -- there's no point in trying to get the order of type variables + -- correct. Nevertheless, we /do/ want to bind the type variables + -- in an outermost `forall` so that we can bring any scoped type + -- variables into scope. As such, we simply quantify the type + -- variables from left to right. + -- See Note [Scoped type variables and class methods] in + -- D.S.TH.Promote.Monad. + let sak_tvbs = changeDTVFlags SpecifiedSpec $ + toposortTyVarsOf $ arg_kis ++ [res_ki] + sak = ravelVanillaDType sak_tvbs [] arg_kis res_ki in + return (Just (LDRKI (Just sak) scoped_tvs sak_tvbs arg_kis res_ki), length arg_kis) LetBindingRHS | Just ty <- OMap.lookup name type_env -> do @@ -852,8 +894,15 @@ promoteLetDecRHS rhs_sort type_env fix_env mb_let_uniq name let_dec_rhs = do -- don't give it a SAK. -- See Note [No SAKs for let-decs with local variables] | otherwise = Nothing + -- If ScopedTypeVariables is enabled, bring all of the type variables + -- from the outermost forall into scope over the RHS. + scoped_tvs_ext <- qIsExtEnabled LangExt.ScopedTypeVariables + let scoped_tvs | scoped_tvs_ext + = OSet.fromList (map extractTvbName tvbs) + | otherwise + = OSet.empty -- invariant: count_args ty == length argKs - return (Just (LDRKI m_sak tvbs argKs resultK), length argKs) + return (Just (LDRKI m_sak scoped_tvs tvbs argKs resultK), length argKs) | otherwise -> return (Nothing, default_num_args) @@ -884,6 +933,13 @@ data LetDecRHSKindInfo = -- This will be Nothing if the let-dec RHS has local -- variables that it closes over. -- See Note [No SAKs for let-decs with local variables] + (OSet Name) -- The scoped type variables to bring into scope over + -- the RHS of the let-dec. This will be a subset of the + -- type variables of the kind (see the field below), + -- but not necessarily the same. See + -- Note [Scoped type variables and class methods] + -- (Wrinkle: Partial scoping) in D.S.TH.Promote.Monad + -- for an example where this can be a proper subset. [DTyVarBndrSpec] -- The type variable binders of the kind. [DKind] -- The argument kinds. DKind -- The result kind. @@ -1034,11 +1090,10 @@ promoteClause mb_let_uniq name m_ldrki all_locals (DClause pats exp) = do -- in the promoted type family equation with its kind. -- See Note [Scoped type variables] in Data.Singletons.TH.Promote.Monad for an -- explanation of why we do this. - scoped_tvs <- qIsExtEnabled LangExt.ScopedTypeVariables let types_w_kinds = case m_ldrki of - Just (LDRKI _ tvbs kinds _) - | not (null tvbs) && scoped_tvs + Just (LDRKI _ scoped_tvs _ kinds _) + | not (OSet.null scoped_tvs) -> zipWith DSigT types kinds _ -> types let PromDPatInfos { prom_dpat_vars = new_vars @@ -1219,7 +1274,7 @@ promoteLetDecName mb_let_uniq name m_ldrki all_locals = do let proName = promotedValueName opts name mb_let_uniq type_args = case m_ldrki of - Just (LDRKI m_sak tvbs _ _) + Just (LDRKI m_sak _ tvbs _ _) | isJust m_sak -- Per the comments on LetDecRHSKindInfo, `isJust m_sak` is only True -- if there are no local variables. Convert the scoped type variables diff --git a/singletons-th/src/Data/Singletons/TH/Promote/Monad.hs b/singletons-th/src/Data/Singletons/TH/Promote/Monad.hs index fa6810e6..83fc1fec 100644 --- a/singletons-th/src/Data/Singletons/TH/Promote/Monad.hs +++ b/singletons-th/src/Data/Singletons/TH/Promote/Monad.hs @@ -432,4 +432,170 @@ scenarios where singletons-th fails to promote scoped type variables: type LetY x :: Maybe b where LetY x :: Maybe b = Nothing :: Maybe b + +Note [Scoped type variables and class methods] +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Implementing support for scoped type variables (see Note [Scoped type variables] +as a primer) in the type signatures of class methods is surprisingly tricky. +First, let's consider a small but illustrative example: + + class C a where + m :: forall b. a -> b -> (a, b) + m x y = (x, y) :: (a, b) + +In the default implementation of `m`, there are /two/ levels of scoped type +variables: + +* The `a` type variable from the `class C a` header. +* The `b` type variable from the method signature `forall b. a -> b -> (a, b)` + +This means that in order to promote `m` to an associated type family, we need +to ensure that both `a` and `b` are brought into scope. Roughly speaking, we +promote `C` and `m` like so: + + class PC a where + type M (x :: a) (y :: b) :: (a, b) + type M x y = MDefault x y + + type MDefault :: forall a b. a -> b -> (a, b) + type family MDefault x y where + MDefault @a @b x y = '(x, y) :: (a, b) + +The most subtle part is defining MDefault, as we need to give it a standalone +kind signature in order to bind `@a` and `@b` in the definition of `MDefault`. +Note that it's not enough to promote the method signature, as that doesn't +quantify `a`. Instead, we simply collect the free variables of the argument and +result types (`a -> b -> a`) and quantify those, giving us `forall a b. a -> b +-> a`. Note that the exact order of type variables doesn't matter, as the user +doesn't invoke MDefault directly. We mainly use the `forall` to ensure /some/ +predictable ordering for the type variables so that we can match the order in +the invisible arguments in the type family equation. + +A similar process applies to class instances. For example: + + instance C [a] where + m :: forall b. [a] -> b -> ([a], b) + m x y = (reverse x, y) :: ([a], b) + +In this example, there are also two levels of scoped type variables: the `a` +from the instance head, and the `b` in the instance signature. We would promote +this instance similarly: + + instance PC [a] where + type M x y = MImpl x y + + type MImpl :: forall a b. [a] -> b -> ([a], b) + type family MImpl x y where + MImpl @a @b x y = '(Reverse x, y) :: ([a], b) + +----- +-- Wrinkle: Partial scoping +----- + +Although the examples above use two levels of scoped type variables, it is not +necessarily the case that you /have/ to use both levels. Consider, for example: + + instance C (Maybe a) where + m :: Maybe a -> b -> (Maybe a, b) + m x y = (fmap (\xx -> (xx :: a)) x, y) + +Note that the `a` scopes over the body of `m`'s implementation, but /not/ `b`, +as `m`'s instance signature does not have an outermost `forall`. A more extreme +version of this example is: + + instance C (Maybe a) where + m x y = (fmap (\xx -> (xx :: a)) x, y) + +Here, `m` does not have an instance signature at all, so there is no `b` in +sight. + +In both examples, we are presented with a challenge: how do we ensure that `a` +(and only `a`) scopes? Note that singletons-th's approach to promoting class +methods means that we will promote this instance to code that looks like: + + instance PC (Maybe a) where + type M x y = MImpl x y + + type MImpl :: forall a b. Maybe a -> b -> (Maybe a, b) + type family MImpl x y where + ... + +We need to give `MImpl` a standalone kind signature we ensure that we can bring +`a` into scope over the right-hand side of `MImpl`'s type family equation. What +does this mean for `b`? One idea is that we could bring `b` into scope over the +right-hand side of the equation as well. This would give rise to this +definition: + + type MImpl :: forall a b. Maybe a -> b -> (Maybe a, b) + type family MImpl x y where + M @a @b x y = (Fmap (LambdaSym1 a b x y) x, y) + + data LambdaSym1 a b x y xx + type instance Apply (LambdaSym1 a b x y) xx = Lambda a b x y xx + + type family Lambda a b x y xx where + Lambda a b x y xx = xx :: a + +Note that Lambda (the lambda-lifted version of the `\xx -> (xx :: a)` +expression) includes both `a` and `b` as local variables. Somewhat +surprisingly, this ends up being a problem when /singling/ the instance. To see +why, consider the singled code for the extreme version of the instance: + + instance SC (Maybe a) where + sM (sX :: Sing x) (sY :: Sing y) = + ( sFmap (singFun1 @(LambdaSym1 a b x y) + (\(sXX :: Sing xx) -> (sXX :: Sing (xx :: a))) + , sY + ) + +GHC will reject this code, as `b` is not in scope in the subexpression +`singFun1 @(LambdaSym1 a b x y)`. And indeed, the original code doesn't bring +`b` into scope, so it makes sense that `b` wouldn't be in scope in the singled +code. We could try to infer an instance signature for `sM` that quantifies `b` +in an outermost `forall`, but doing so is fraught with peril (see #590). + +Luckily, there is a relatively simple way to make this work. The reason that +LambdaSym1 includes `b` as an argument is because we typically call +`scopedBind` (see Note [Scoped type variables]) on all of the type variables +bound in the outermost `forall` to bring them into scope in the right-hand +side. For class methods, however, we need not call `scopedBind` on /every/ type +variable in the outermost `forall`. Instead, we can only call `scopedBind` on +the type variables that actually interact with ScopedTypeVariables, and we can +leave all other type variables alone. Concretely, this means that we would +generate the following code for `MImpl`: + + type MImpl :: forall a b. Maybe a -> b -> (Maybe a, b) + type family MImpl x y where + M @a @b x y = + -- NB: Call `scopedBind [a]` here, not `scopedBind [a, b]` + (Fmap (LambdaSym1 a x y) x, y) + + data LambdaSym1 a x y xx + type instance Apply (LambdaSym1 a x y) xx = Lambda a x y xx + + type family Lambda a x y xx where + Lambda a x y xx = xx :: a + +Note that we still bind `@b` in an invisible argument, but we no longer pass it +along to LambdaSym1. This means that when we generate `singFun1 @(LambdaSym1 a +x y)` in the singled instance, we no longer reference `b` at all, avoiding the +issue above. (Note that we don't need to bind `@b` in an invisible argument +anymore, but it would require more work to special-case class methods in +`promoteClause` to avoid this, and it doesn't hurt anything to leave `@b` in +place). + +The `OSet Name` fields of `ClassMethodRHS` dictates which type variables to +bring into scope via `scopedBind`. There are multiple places in the code which +determine which type variables get put into the `OSet`: + +* For class declarations, the scoped type variables from the class header + (e.g., the `a` in `class C a`) are determined in `promoteClassDec`. +* For instance declarations, the scoped type variables from the instance head + (e.g., the `a` in `instance C (Maybe a)`) are determined in + `promoteInstanceDec`. +* The scoped type variables from class method signatures and instance signatures + are determined in `promoteMethod.promote_meth_ty`. + +Each of these functions have references to this Note near the particular lines +of relevant code. -} diff --git a/singletons-th/src/Data/Singletons/TH/Single.hs b/singletons-th/src/Data/Singletons/TH/Single.hs index 292eec1c..c118a1a2 100644 --- a/singletons-th/src/Data/Singletons/TH/Single.hs +++ b/singletons-th/src/Data/Singletons/TH/Single.hs @@ -476,22 +476,7 @@ singInstD (InstDecl { id_cxt = cxt, id_name = inst_name, id_arg_tys = inst_tys sing_meth :: Name -> ALetDecRHS -> SgM [DDec] sing_meth name rhs = do opts <- getOptions - mb_s_info <- dsReify (singledValueName opts name) - inst_kis <- mapM promoteType inst_tys - let mk_subst cls_tvbs = Map.fromList $ zip (map extractTvbName vis_cls_tvbs) inst_kis - where - -- This is a half-hearted attempt to address the underlying problem - -- in #358, where we can sometimes have more class type variables - -- (due to implicit kind arguments) than class arguments. This just - -- ensures that the explicit type variables are properly mapped - -- to the class arguments, leaving the implicit kind variables - -- unmapped. That could potentially cause *other* problems, but - -- those are perhaps best avoided by using InstanceSigs. At the - -- very least, this workaround will make error messages slightly - -- less confusing. - vis_cls_tvbs = drop (length cls_tvbs - length inst_kis) cls_tvbs - - sing_meth_ty :: DType -> SgM DType + let sing_meth_ty :: DType -> SgM DType sing_meth_ty inner_ty = do -- Make sure to expand through type synonyms here! Not doing so -- resulted in #167. @@ -500,24 +485,12 @@ singInstD (InstDecl { id_cxt = cxt, id_name = inst_name, id_arg_tys = inst_tys <- singType (DConT $ defunctionalizedName0 opts name) raw_ty pure s_ty - s_ty <- case OMap.lookup name inst_sigs of - Just inst_sig -> - -- We have an InstanceSig, so just single that type. - sing_meth_ty inst_sig - Nothing -> case mb_s_info of - -- We don't have an InstanceSig, so we must compute the type to use - -- in the singled instance ourselves through reification. - Just (DVarI _ (DForallT (DForallInvis cls_tvbs) (DConstrainedT _cls_pred s_ty)) _) -> - pure $ substType (mk_subst cls_tvbs) s_ty - _ -> do - mb_info <- dsReify name - case mb_info of - Just (DVarI _ (DForallT (DForallInvis cls_tvbs) - (DConstrainedT _cls_pred inner_ty)) _) -> do - s_ty <- sing_meth_ty inner_ty - pure $ substType (mk_subst cls_tvbs) s_ty - _ -> fail $ "Cannot find type of method " ++ show name - + -- If an instance signature exists, single it. Otherwise, leave it out. + -- Unlike most other places, we don't actually *need* explicit type + -- signatures for instance methods, as GHC can figure out the types of + -- the instance methods on its own. As such, any GADT pattern matching in + -- the singled instance method code will work as expected. + mb_s_ty <- traverse sing_meth_ty $ OMap.lookup name inst_sigs meth' <- singLetDecRHS Map.empty -- Because we are singling an instance declaration, -- we aren't generating defunctionalization symbols @@ -525,7 +498,9 @@ singInstD (InstDecl { id_cxt = cxt, id_name = inst_name, id_arg_tys = inst_tys -- generating any SingI instances. Therefore, we -- don't need to include anything in this Map. name rhs - return $ map DLetDec [DSigD (singledValueName opts name) s_ty, meth'] + return $ map DLetDec + $ maybeToList (DSigD (singledValueName opts name) <$> mb_s_ty) + ++ [meth'] singLetDecEnv :: ALetDecEnv -> SgM a