summaryrefslogtreecommitdiff
path: root/testsuite/tests/ghc-regress/module/mod110.hs
blob: 897dd12cdb8863cf4443b8644611c92dc4f9859d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
-- !!! Re-defining Prelude class
module M where

import Prelude
--import qualified Prelude

class Eq a where
 equal  :: a -> a -> Prelude.Bool
 negate :: a -> a

instance Eq Prelude.Int where
  equal x y = x Prelude.== y
  negate x  = Prelude.negate x
x = M.negate (2 :: Prelude.Int)