4274bee7dd48d49e5edeaa8f29784d207f0a8b1c
[ghc-hetmet.git] / ghc / tests / typecheck / should_compile / tc115.hs
1 {-# OPTIONS -w -fglasgow-exts #-}
2
3 -- !!! Functional dependencies
4 -- This broke an early impl of functional dependencies
5 -- (complaining about ambiguity)
6
7 module ShouldCompile where
8
9 class Foo r a | r -> a where
10     foo :: r -> a
11
12 instance Foo [m a] (m a)
13
14 bad:: Monad m => m a
15 bad = foo bar
16
17 bar:: Monad m => [m a]
18 bar = []