summaryrefslogtreecommitdiff
path: root/testsuite/tests/generics/T10604/T10604_deriving.hs
blob: 5bdf586e75aadad52f664b2b9ac5c8be8ab98446 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveFunctor #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE PolyKinds #-}
{-# OPTIONS_GHC -ddump-deriv -fprint-explicit-kinds #-}
module T10604_deriving where

import GHC.Generics

data Empty (a :: Bool)
  deriving (Generic, Generic1)
data Proxy (a :: k) = Proxy
  deriving (Functor, Generic, Generic1)
data Wrap (a :: * -> *) = Wrap (Proxy a)
  deriving (Generic, Generic1)
data Wrap2 (a :: k -> *) = Wrap2 (Proxy (Proxy a))
  deriving (Generic, Generic1)
data SumOfProducts a = Prod1 (Proxy a) (Proxy a) | Prod2 (Proxy a) (Proxy a)
  deriving (Generic, Generic1)

data Starify a = Starify1 a | Starify2 Int
  deriving (Generic, Generic1)