[project @ 1997-09-08 09:48:01 by simonm]
[ghc-hetmet.git] / ghc / tests / typecheck / should_run / tcrun001.hs
1 --!! Test for (->) instances
2
3 module ShouldRun where
4
5 class Flob k where
6   twice :: k a a  -> k a a
7
8 instance Flob (->) where
9   twice f = f . f
10
11 inc :: Int -> Int
12 inc x = x+1
13
14 main = print (twice inc 2)
15
16