[GHC] #11182: -XStrict doesn't imply -XStrictData
GHC
ghc-devs at haskell.org
Tue Dec 8 20:21:35 UTC 2015
#11182: -XStrict doesn't imply -XStrictData
-------------------------------------+-------------------------------------
Reporter: RyanGlScott | Owner:
Type: bug | Status: new
Priority: normal | Milestone: 8.0.1
Component: Compiler | Version: 7.11
Keywords: | Operating System: Unknown/Multiple
Architecture: | Type of failure: GHC rejects
Unknown/Multiple | valid program
Test Case: | Blocked By:
Blocking: | Related Tickets: #8347
Differential Rev(s): | Wiki Page:
-------------------------------------+-------------------------------------
Compiling this code:
{{{#!hs
{-# LANGUAGE Strict #-}
data Lazy a = Lazy ~a
main :: IO ()
main = case Lazy undefined of
Lazy _ -> putStrLn "Lazy"
}}}
fails with the following error:
{{{
$ .\inplace\bin\ghc-stage2.exe ../Lazy.hs
[1 of 1] Compiling Main ( ..\Lazy.hs, ..\Lazy.o )
..\Lazy.hs:3:15: error:
* Lazy annotation (~) without StrictData
on the first argument of `Lazy'
* In the definition of data constructor `Lazy'
In the data type declaration for `Lazy'
}}}
I was under the impression that `-XStrict` implied `-XStrictData`. Is this
not the case?
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11182>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list