summaryrefslogtreecommitdiff
path: root/testsuite/tests/th/T7910.hs
blob: d62afc8160a74ae694f4d282b3c0202f7fb8d9f6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE TemplateHaskell #-}
module Main where

import Language.Haskell.TH
import Language.Haskell.TH.Syntax

class C a
instance C Int

type D a = C a

$(return [])

main = print $(
  do isCInst <- isInstance ''C [ConT ''Int]
     isDInst <- isInstance ''D [ConT ''Int]
     lift (isCInst,isDInst))