#1871: compile warning appears to be treated as error
-------------------------------+--------------------------------------------
Reporter: duncan | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 6.8.1
Severity: normal | Keywords:
Difficulty: Unknown | Testcase:
Architecture: x86_64 (amd64) | Os: Linux
-------------------------------+--------------------------------------------
In regex-base-0.92 it has a module re-export:
{{{
module Text.Regex.Base (
...
,module Text.Regex.Base.Context
) where
}}}
that module exports nothing except instances:
{{{
module Text.Regex.Base.Context() where
}}}
On compiling this we Cabal which uses ghc-6.8.1 --make ghc reports:
{{{
[1 of 4] Compiling Text.Regex.Base.RegexLike (
Text/Regex/Base/RegexLike.hs, dist/build/Text/Regex/Base/RegexLike.o )
[2 of 4] Compiling Text.Regex.Base.Context ( Text/Regex/Base/Context.hs,
dist/build/Text/Regex/Base/Context.o )
Warning: orphan instances:
instance Text.Regex.Base.RegexLike.RegexContext [., .,
-- snip lots of orphan instances
[3 of 4] Compiling Text.Regex.Base ( Text/Regex/Base.hs,
dist/build/Text/Regex/Base.o )
Text/Regex/Base.hs:48:3:
Warning: The export item `module Text.Regex.Base.Context' exports
nothing
}}}
and that's it. It returns a failure exit code at this point. It does not
continue on to compile the 4th module.
Apparently compiling each module individually works. And ghc-6.6.1 --make
works.
To reproduce, use ghc-6.8.1 with the bundled Cabal and grab regex-
base-0.92 from hackage http://hackage.haskell.org/packages/archive/regex-
base/0.92/regex-base-0.92.tar.gz
You need to add the three missing package deps to the .cabal file,
containers, array and bytestring.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/1871>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs