singletons-2.6: tests/compile-and-dump/Singletons/T167.ghc88.template
Singletons/T167.hs:(0,0)-(0,0): Splicing declarations
singletonsOnly
[d| class Foo a where
foosPrec :: Nat -> a -> DiffList
fooList :: a -> DiffList
fooList = undefined
instance Foo a => Foo [a] where
foosPrec _ = fooList |]
======>
type FoosPrecSym3 (arg0123456789876543210 :: Nat) (arg0123456789876543210 :: a0123456789876543210) (arg0123456789876543210 :: [Bool]) =
FoosPrec arg0123456789876543210 arg0123456789876543210 arg0123456789876543210
instance SuppressUnusedWarnings (FoosPrecSym2 arg0123456789876543210 arg0123456789876543210) where
suppressUnusedWarnings = snd (((,) FoosPrecSym2KindInference) ())
data FoosPrecSym2 (arg0123456789876543210 :: Nat) (arg0123456789876543210 :: a0123456789876543210) :: (~>) [Bool] [Bool]
where
FoosPrecSym2KindInference :: forall arg0123456789876543210
arg0123456789876543210
arg0123456789876543210
arg. SameKind (Apply (FoosPrecSym2 arg0123456789876543210 arg0123456789876543210) arg) (FoosPrecSym3 arg0123456789876543210 arg0123456789876543210 arg) =>
FoosPrecSym2 arg0123456789876543210 arg0123456789876543210 arg0123456789876543210
type instance Apply (FoosPrecSym2 arg0123456789876543210 arg0123456789876543210) arg0123456789876543210 = FoosPrec arg0123456789876543210 arg0123456789876543210 arg0123456789876543210
instance SuppressUnusedWarnings (FoosPrecSym1 arg0123456789876543210) where
suppressUnusedWarnings = snd (((,) FoosPrecSym1KindInference) ())
data FoosPrecSym1 (arg0123456789876543210 :: Nat) :: forall a0123456789876543210.
(~>) a0123456789876543210 ((~>) [Bool] [Bool])
where
FoosPrecSym1KindInference :: forall arg0123456789876543210
arg0123456789876543210
arg. SameKind (Apply (FoosPrecSym1 arg0123456789876543210) arg) (FoosPrecSym2 arg0123456789876543210 arg) =>
FoosPrecSym1 arg0123456789876543210 arg0123456789876543210
type instance Apply (FoosPrecSym1 arg0123456789876543210) arg0123456789876543210 = FoosPrecSym2 arg0123456789876543210 arg0123456789876543210
instance SuppressUnusedWarnings FoosPrecSym0 where
suppressUnusedWarnings = snd (((,) FoosPrecSym0KindInference) ())
data FoosPrecSym0 :: forall a0123456789876543210.
(~>) Nat ((~>) a0123456789876543210 ((~>) [Bool] [Bool]))
where
FoosPrecSym0KindInference :: forall arg0123456789876543210
arg. SameKind (Apply FoosPrecSym0 arg) (FoosPrecSym1 arg) =>
FoosPrecSym0 arg0123456789876543210
type instance Apply FoosPrecSym0 arg0123456789876543210 = FoosPrecSym1 arg0123456789876543210
type FooListSym2 (arg0123456789876543210 :: a0123456789876543210) (arg0123456789876543210 :: [Bool]) =
FooList arg0123456789876543210 arg0123456789876543210
instance SuppressUnusedWarnings (FooListSym1 arg0123456789876543210) where
suppressUnusedWarnings = snd (((,) FooListSym1KindInference) ())
data FooListSym1 (arg0123456789876543210 :: a0123456789876543210) :: (~>) [Bool] [Bool]
where
FooListSym1KindInference :: forall arg0123456789876543210
arg0123456789876543210
arg. SameKind (Apply (FooListSym1 arg0123456789876543210) arg) (FooListSym2 arg0123456789876543210 arg) =>
FooListSym1 arg0123456789876543210 arg0123456789876543210
type instance Apply (FooListSym1 arg0123456789876543210) arg0123456789876543210 = FooList arg0123456789876543210 arg0123456789876543210
instance SuppressUnusedWarnings FooListSym0 where
suppressUnusedWarnings = snd (((,) FooListSym0KindInference) ())
data FooListSym0 :: forall a0123456789876543210.
(~>) a0123456789876543210 ((~>) [Bool] [Bool])
where
FooListSym0KindInference :: forall arg0123456789876543210
arg. SameKind (Apply FooListSym0 arg) (FooListSym1 arg) =>
FooListSym0 arg0123456789876543210
type instance Apply FooListSym0 arg0123456789876543210 = FooListSym1 arg0123456789876543210
type family FooList_0123456789876543210 (a :: a) (a :: [Bool]) :: [Bool] where
FooList_0123456789876543210 a_0123456789876543210 a_0123456789876543210 = Apply (Apply UndefinedSym0 a_0123456789876543210) a_0123456789876543210
type FooList_0123456789876543210Sym2 (a0123456789876543210 :: a0123456789876543210) (a0123456789876543210 :: [Bool]) =
FooList_0123456789876543210 a0123456789876543210 a0123456789876543210
instance SuppressUnusedWarnings (FooList_0123456789876543210Sym1 a0123456789876543210) where
suppressUnusedWarnings
= snd (((,) FooList_0123456789876543210Sym1KindInference) ())
data FooList_0123456789876543210Sym1 (a0123456789876543210 :: a0123456789876543210) :: (~>) [Bool] [Bool]
where
FooList_0123456789876543210Sym1KindInference :: forall a0123456789876543210
a0123456789876543210
arg. SameKind (Apply (FooList_0123456789876543210Sym1 a0123456789876543210) arg) (FooList_0123456789876543210Sym2 a0123456789876543210 arg) =>
FooList_0123456789876543210Sym1 a0123456789876543210 a0123456789876543210
type instance Apply (FooList_0123456789876543210Sym1 a0123456789876543210) a0123456789876543210 = FooList_0123456789876543210 a0123456789876543210 a0123456789876543210
instance SuppressUnusedWarnings FooList_0123456789876543210Sym0 where
suppressUnusedWarnings
= snd (((,) FooList_0123456789876543210Sym0KindInference) ())
data FooList_0123456789876543210Sym0 :: forall a0123456789876543210.
(~>) a0123456789876543210 ((~>) [Bool] [Bool])
where
FooList_0123456789876543210Sym0KindInference :: forall a0123456789876543210
arg. SameKind (Apply FooList_0123456789876543210Sym0 arg) (FooList_0123456789876543210Sym1 arg) =>
FooList_0123456789876543210Sym0 a0123456789876543210
type instance Apply FooList_0123456789876543210Sym0 a0123456789876543210 = FooList_0123456789876543210Sym1 a0123456789876543210
class PFoo (a :: GHC.Types.Type) where
type FoosPrec (arg :: Nat) (arg :: a) (arg :: [Bool]) :: [Bool]
type FooList (arg :: a) (arg :: [Bool]) :: [Bool]
type FooList a a = Apply (Apply FooList_0123456789876543210Sym0 a) a
type family FoosPrec_0123456789876543210 (a :: Nat) (a :: [a]) (a :: [Bool]) :: [Bool] where
FoosPrec_0123456789876543210 _ a_0123456789876543210 a_0123456789876543210 = Apply (Apply FooListSym0 a_0123456789876543210) a_0123456789876543210
type FoosPrec_0123456789876543210Sym3 (a0123456789876543210 :: Nat) (a0123456789876543210 :: [a0123456789876543210]) (a0123456789876543210 :: [Bool]) =
FoosPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210
instance SuppressUnusedWarnings (FoosPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) where
suppressUnusedWarnings
= snd (((,) FoosPrec_0123456789876543210Sym2KindInference) ())
data FoosPrec_0123456789876543210Sym2 (a0123456789876543210 :: Nat) (a0123456789876543210 :: [a0123456789876543210]) :: (~>) [Bool] [Bool]
where
FoosPrec_0123456789876543210Sym2KindInference :: forall a0123456789876543210
a0123456789876543210
a0123456789876543210
arg. SameKind (Apply (FoosPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) arg) (FoosPrec_0123456789876543210Sym3 a0123456789876543210 a0123456789876543210 arg) =>
FoosPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210 a0123456789876543210
type instance Apply (FoosPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210) a0123456789876543210 = FoosPrec_0123456789876543210 a0123456789876543210 a0123456789876543210 a0123456789876543210
instance SuppressUnusedWarnings (FoosPrec_0123456789876543210Sym1 a0123456789876543210) where
suppressUnusedWarnings
= snd (((,) FoosPrec_0123456789876543210Sym1KindInference) ())
data FoosPrec_0123456789876543210Sym1 (a0123456789876543210 :: Nat) :: forall a0123456789876543210.
(~>) [a0123456789876543210] ((~>) [Bool] [Bool])
where
FoosPrec_0123456789876543210Sym1KindInference :: forall a0123456789876543210
a0123456789876543210
arg. SameKind (Apply (FoosPrec_0123456789876543210Sym1 a0123456789876543210) arg) (FoosPrec_0123456789876543210Sym2 a0123456789876543210 arg) =>
FoosPrec_0123456789876543210Sym1 a0123456789876543210 a0123456789876543210
type instance Apply (FoosPrec_0123456789876543210Sym1 a0123456789876543210) a0123456789876543210 = FoosPrec_0123456789876543210Sym2 a0123456789876543210 a0123456789876543210
instance SuppressUnusedWarnings FoosPrec_0123456789876543210Sym0 where
suppressUnusedWarnings
= snd (((,) FoosPrec_0123456789876543210Sym0KindInference) ())
data FoosPrec_0123456789876543210Sym0 :: forall a0123456789876543210.
(~>) Nat ((~>) [a0123456789876543210] ((~>) [Bool] [Bool]))
where
FoosPrec_0123456789876543210Sym0KindInference :: forall a0123456789876543210
arg. SameKind (Apply FoosPrec_0123456789876543210Sym0 arg) (FoosPrec_0123456789876543210Sym1 arg) =>
FoosPrec_0123456789876543210Sym0 a0123456789876543210
type instance Apply FoosPrec_0123456789876543210Sym0 a0123456789876543210 = FoosPrec_0123456789876543210Sym1 a0123456789876543210
instance PFoo [a] where
type FoosPrec a a a = Apply (Apply (Apply FoosPrec_0123456789876543210Sym0 a) a) a
class SFoo a where
sFoosPrec ::
forall (t :: Nat) (t :: a) (t :: [Bool]).
Sing t
-> Sing t
-> Sing t
-> Sing (Apply (Apply (Apply FoosPrecSym0 t) t) t :: [Bool])
sFooList ::
forall (t :: a) (t :: [Bool]).
Sing t -> Sing t -> Sing (Apply (Apply FooListSym0 t) t :: [Bool])
default sFooList ::
forall (t :: a) (t :: [Bool]).
((Apply (Apply FooListSym0 t) t :: [Bool])
~ Apply (Apply FooList_0123456789876543210Sym0 t) t) =>
Sing t -> Sing t -> Sing (Apply (Apply FooListSym0 t) t :: [Bool])
sFooList
(sA_0123456789876543210 :: Sing a_0123456789876543210)
(sA_0123456789876543210 :: Sing a_0123456789876543210)
= (sUndefined sA_0123456789876543210) sA_0123456789876543210
instance SFoo a => SFoo [a] where
sFoosPrec ::
forall (t :: Nat) (t :: [a]) (t :: [Bool]).
Sing t
-> Sing t
-> Sing t
-> Sing (Apply (Apply (Apply FoosPrecSym0 t) t) t :: [Bool])
sFoosPrec
_
(sA_0123456789876543210 :: Sing a_0123456789876543210)
(sA_0123456789876543210 :: Sing a_0123456789876543210)
= (applySing
((applySing ((singFun2 @FooListSym0) sFooList))
sA_0123456789876543210))
sA_0123456789876543210
instance SFoo a =>
SingI (FoosPrecSym0 :: (~>) Nat ((~>) a ((~>) [Bool] [Bool]))) where
sing = (singFun3 @FoosPrecSym0) sFoosPrec
instance (SFoo a, SingI d) =>
SingI (FoosPrecSym1 (d :: Nat) :: (~>) a ((~>) [Bool] [Bool])) where
sing = (singFun2 @(FoosPrecSym1 (d :: Nat))) (sFoosPrec (sing @d))
instance (SFoo a, SingI d, SingI d) =>
SingI (FoosPrecSym2 (d :: Nat) (d :: a) :: (~>) [Bool] [Bool]) where
sing
= (singFun1 @(FoosPrecSym2 (d :: Nat) (d :: a)))
((sFoosPrec (sing @d)) (sing @d))
instance SFoo a =>
SingI (FooListSym0 :: (~>) a ((~>) [Bool] [Bool])) where
sing = (singFun2 @FooListSym0) sFooList
instance (SFoo a, SingI d) =>
SingI (FooListSym1 (d :: a) :: (~>) [Bool] [Bool]) where
sing = (singFun1 @(FooListSym1 (d :: a))) (sFooList (sing @d))