summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_fail/tcfail114.hs
blob: a9305ad190806de787ca4beb36bec1aecf0c8086 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
-- Killed GHC 5.04.2

module ShouldFail where

class Foo a where
  foo :: a -> ()

data Bar = Bar { bar :: () }

test :: Bar
test = undefined { foo = () }
        -- The point is that foo is a class method,
        -- but not a record selector