
#8739: ($) returning kind # no longer type checks ------------------------------------+------------------------------------- Reporter: NeilMitchell | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.8.1-rc1 Keywords: | Operating System: Unknown/Multiple Architecture: Unknown/Multiple | Type of failure: None/Unknown Difficulty: Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | ------------------------------------+------------------------------------- Given: {{{ {-# LANGUAGE MagicHash #-} module InnerLoop(go) where import GHC.Exts go :: () -> Int# go () = go $ () }}} This type checks fine on GHC 7.2.3, and I have a similar version that works fine with 7.4 and 7.6. However, with GHC 7.8.20140130, I get: {{{ InnerLoop.hs:5:9: Kind incompatibility when matching types: s0 :: * Int# :: # In the expression: go $ () In an equation for `go': go () = go $ () }}} This code was reduced from [http://neilmitchell.blogspot.co.uk/2014/01 /optimising-haskell-for-tight-inner-loop.html this blog post], and code which triggers a similar bug can be [https://github.com/ndmitchell/shake/issues/94 found in Shake]. I know {{{$}}} has special type checking rules, were they removed or changed? -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/8739 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler