projects
/
ghc-hetmet.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
38e79743e4e2fb88e79946e36f66420019878cd0
[ghc-hetmet.git]
/
ghc
/
tests
/
typecheck
/
should_compile
/
tc113.hs
1
-- !!! Monomorphism restriction
2
3
module ShouldCompile where
4
5
foo :: Eq a => a -> b -> b
6
foo x y = y
7
8
-- Expect test2 :: forall b. b->b
9
-- despite the monomorphism restriction
10
poly = foo (3::Int)
11
12
-- Check that test2 is polymorphic
13
test = (poly True, poly 'c')