[GHC] #11505: Boot file problem
GHC
ghc-devs at haskell.org
Thu Jan 28 14:51:24 UTC 2016
#11505: Boot file problem
-------------------------------------+-------------------------------------
Reporter: augustss | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 7.8.3
Keywords: | Operating System: Unknown/Multiple
Architecture: | Type of failure: None/Unknown
Unknown/Multiple |
Test Case: | Blocked By:
Blocking: | Related Tickets:
Differential Rev(s): | Wiki Page:
-------------------------------------+-------------------------------------
Here are two modules and a boot file.
Compile by
{{{
ghc -c Foo.hs-boot; ghc -c Bar.hs; ghc -c Foo.hs
}}}
and observe this error message
{{{
Foo.hs:12:1:
Type constructor `Foo' has conflicting definitions in the module
and its hs-boot file
Main module: data Foo = Foo {x :: {-# UNPACK #-} !Int}
Boot file: data Foo = Foo {x :: !Int}
}}}
But the definitions are not conflicting, they are identical.
Foo.hs-boot:
{{{
module Foo where
data Foo = Foo { x :: {-# UNPACK #-} !Int }
}}}
Foo.hs:
{{{
module Foo where
import Bar
data Foo = Foo { x :: {-# UNPACK #-} !Int }
}}}
Bar.hs:
{{{
module Bar where
import {-# SOURCE #-} Foo
}}}
Removing the unbox pragma gives the even more perplexing:
{{{
Foo.hs:3:1:
Type constructor `Foo' has conflicting definitions in the module
and its hs-boot file
Main module: data Foo = Foo {x :: !Int}
Boot file: data Foo = Foo {x :: !Int}
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11505>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list