
#12911: Levity polymorphism check eliminates non-levity-polymorphic data constructor -------------------------------------+------------------------------------- Reporter: goldfire | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.0.1 Keywords: | Operating System: Unknown/Multiple LevityPolymorphism | Architecture: | Type of failure: None/Unknown Unknown/Multiple | Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- When I say {{{ data X where MkX :: forall (a :: TYPE r). (a -> a) -> X }}} I get {{{ • A representation-polymorphic type is not allowed here: Type: a Kind: TYPE r • In the definition of data constructor ‘MkX’ In the data type declaration for ‘X’ }}} But that's silly, because the type is not levity-polymorphic! -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12911 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler