summaryrefslogtreecommitdiff
path: root/testsuite/tests/polykinds/T11616.hs
blob: 378032b7ed4969b29083cb4c78554f6b809cc6f6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
{-# LANGUAGE AllowAmbiguousTypes #-}
{-# LANGUAGE TypeApplications #-}
{-# LANGUAGE TypeInType #-}
module T11616 where

class Whoami a where
  whoami :: String

instance Whoami Int where
  whoami = "int"

instance Whoami Bool where
  whoami = "[y/n]"

instance Whoami Maybe where
  whoami = "call me maybe"

whoisint :: String
whoisint = whoami @Int