blob: a99b956098f2a097d9c4a7bca90ca5c736f8e171 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
-- Killed 6.2.2
-- The trouble was that 1 was instantiated to a type (t::?)
-- and the constraint (Foo (t::? -> s::*)) didn't match Foo (a::* -> b::*).
-- Solution is to zap the expected type in TcEpxr.tc_expr(HsOverLit).
module ShouldCompile where
class Foo a where
foo :: a
instance Foo (a -> b) where
foo = error "urk"
test :: ()
test = foo 1
|