SCC analysis for instances as well as types/classes
[ghc.git] / testsuite / tests / typecheck / should_compile / tc200.hs
1 {-# OPTIONS_GHC -w #-}
2 {-# LANGUAGE ConstrainedClassMethods #-} -- Needed for 'baz'
3
4 -- A nasty case that crashed GHC 6.4 with a Lint error;
5 -- see Note [Multiple instantiation] in TcExpr
6
7 module ShouldCompile where
8
9 class C a where
10 foo :: Eq b => b -> a -> Int
11 baz :: Eq a => Int -> a -> Int
12
13 instance C Int where
14 baz = foo