summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_compile/T13474.hs
blob: 977583244b619c1b27d012874584ce3cbee39376 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
module T13474 where

import qualified Data.Map as M

class Default a where
  def :: a

foo :: Default a => b -> a
foo x = def

mapdef :: Default v => M.Map k v -> M.Map k v
mapdef = M.map foo