Panic while forcing the thunk for TyThing IsFile (regression)
(Apologies in advance for the very non-minimal testcase. I have been unsuccessfully trying to reduce the testcase for a few hours now, but I am flying blind, and the bug seems to depend on the interaction of various modules. The panic is very reproducible for me, so I figured that better reporting even if I failed to obtain a simplified testcase. Maybe someone else has more luck isolating the issue.)
When compiling gi-gio-2.0.12
I consistently get the following GHC panic:
[259 of 293] Compiling GI.Gio.Interfaces.File ( GI/Gio/Interfaces/File.hs, dist/build/GI/Gio/Interfaces/File.o )
ghc: panic! (the 'impossible' happened)
(GHC version 8.2.0.20170507 for x86_64-unknown-linux):
tcIfaceGlobal (local): not found
You are in a maze of twisty little passages, all alike.
While forcing the thunk for TyThing IsFile
which was lazily initialized by initIfaceCheck typecheckLoop,
I tried to tie the knot, but I couldn't find IsFile
in the current type environment.
If you are developing GHC, please read Note [Tying the knot]
and Note [Type-checking inside the knot].
Consider rebuilding GHC with profiling for a better stack trace.
Contents of current type environment: []
Call stack:
CallStack (from HasCallStack):
prettyCurrentCallStack, called at compiler/utils/Outputable.hs:1134:58 in ghc:Outputable
callStackDoc, called at compiler/utils/Outputable.hs:1138:37 in ghc:Outputable
pprPanic, called at compiler/iface/TcIface.hs:1689:23 in ghc:TcIface
Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug
To compile this code you will need the glib2-devel
package installed. To compile
$ cabal get gi-gio-2.0.12
$ cd gi-gio-2.0.12
$ cabal sandbox init
$ cabal install --dependencies-only
$ cabal build
I am running version 8.2.0.20170507
, from https://copr.fedorainfracloud.org/coprs/petersen/ghc-8.2.1/ .
The same code compiles in versions 7.8.x
, 7.10.x
and 8.0.x
.
Trac metadata
Trac field | Value |
---|---|
Version | 8.2.1-rc2 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | |
Architecture |