Type families + hs-boot files = panic (type family consistency check too early)
I have these modules:
A.hs-boot:
{-# LANGUAGE TypeFamilies #-}
module A where
type family F a
B.hs:
{-# LANGUAGE TypeFamilies #-}
module B where
import {-# SOURCE #-} A
type instance F Int = Bool
A.hs:
{-# LANGUAGE TypeFamilies #-}
module A where
import B
type family F a
And now this happens:
rae:11:50:47 ~/temp/bug> ~/Documents/ghc-cur/inplace/bin/ghc-stage2 --version
The Glorious Glasgow Haskell Compilation System, version 7.11.20151104
rae:11:50:50 ~/temp/bug> ~/Documents/ghc-cur/inplace/bin/ghc-stage2 -c A.hs-boot
rae:11:50:52 ~/temp/bug> ~/Documents/ghc-cur/inplace/bin/ghc-stage2 -c B.hs
rae:11:50:54 ~/temp/bug> ~/Documents/ghc-cur/inplace/bin/ghc-stage2 -c A.hs
ghc-stage2: panic! (the 'impossible' happened)
(GHC version 7.11.20151104 for x86_64-apple-darwin):
tcIfaceGlobal (local): not found:
F
[]
Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug
rae:11:50:57 ~/temp/bug>
The problem occurs only in one-shot mode.
Trac metadata
| Trac field | Value |
|---|---|
| Version | 7.11 |
| Type | Bug |
| TypeOfFailure | OtherFailure |
| Priority | high |
| Resolution | Unresolved |
| Component | Compiler |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | |
| Operating system | |
| Architecture |
Edited by Edward Z. Yang