Add GHCi help message for :def! and :: commands
[ghc.git] / testsuite / tests / typecheck / should_compile / T12923.hs
1 {-# LANGUAGE ExtendedDefaultRules #-}
2 {-# LANGUAGE MultiParamTypeClasses #-}
3 {-# LANGUAGE FlexibleInstances #-}
4 {-# LANGUAGE KindSignatures #-}
5 {-# LANGUAGE DataKinds #-}
6
7 module T12923 where
8
9 -- Test that ExtendedDefaultRules defaults multiparameter typeclasses with only
10 -- one parameter of kind Type.
11 class Works a (b :: Bool) where
12 works :: a -> A b
13
14 data A (b :: Bool) = A deriving Show
15
16 instance Works Integer 'True where works _ = A
17
18 main :: IO ()
19 main = print (works 5 :: A 'True)