
#9569: Tuple constraints don't work right -------------------------------------+------------------------------------- Reporter: simonpj | Owner: Type: bug | Status: closed Priority: normal | Milestone: Component: Compiler | Version: 7.8.2 Resolution: fixed | Keywords: Operating System: | Architecture: Unknown/Multiple Unknown/Multiple | Difficulty: Unknown Type of failure: | Blocked By: None/Unknown | Related Tickets: Test Case: | polykinds/T9569, | typecheck/should_compile/T9569a | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Comment (by luite): The commit for this changes behaviour of impredicative types, the following does not typecheck anymore: {{{#!hs {-# LANGUAGE ImpredicativeTypes #-} f :: ((forall a. a -> a) -> b) -> b f x = x id g :: ((a -> b) -> c) -> ((a -> b) -> c) g = id h :: ((forall a. a -> a) -> b) -> b h = g f }}} I get the following error: {{{ test.hs:10:7: Couldn't match expected type ‘forall a. a -> a’ with actual type ‘a0 -> a0’ In the first argument of ‘g’, namely ‘f’ In the expression: g f Failed, modules loaded: none. }}} -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9569#comment:5 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler