panic! (the 'impossible' happened) GHC version 9.6.1: ltPSize Ranked
Summary
GHC 9.4.5 says
[17 of 22] Compiling HordeAd.Core.AstInterpret ( simplified/HordeAd/Core/AstInterpret.hs, /home/mikolaj/r/horde-ad/dist-newstyle/build/x86_64-linux/ghc-9.4.5/horde-ad-0.1.0.0/l/horde-ad-simplified/noopt/build/horde-ad-simplified/HordeAd/Core/AstInterpret.o, /home/mikolaj/r/horde-ad/dist-newstyle/build/x86_64-linux/ghc-9.4.5/horde-ad-0.1.0.0/l/horde-ad-simplified/noopt/build/horde-ad-simplified/HordeAd/Core/AstInterpret.dyn_o ) [Source file changed]
simplified/HordeAd/Core/AstInterpret.hs:102:10: error:
• Illegal nested constraint ‘c (Ranked r y)’
(Use UndecidableInstances to permit this)
• In the instance declaration for ‘CRanked2 c r’
|
102 | instance (forall y. KnownNat y => c (Ranked r y)) => CRanked2 c r where
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error: cabal: Failed to build lib:horde-ad-simplified from horde-ad-0.1.0.0
(which is required by test:shortTestForCISimplified from horde-ad-0.1.0.0,
test:extremelyLongTestSimplified from horde-ad-0.1.0.0 and others).
while GHC 9.6.1 panics
[17 of 22] Compiling HordeAd.Core.AstInterpret ( simplified/HordeAd/Core/AstInterpret.hs, /home/mikolaj/r/horde-ad/dist-newstyle/build/x86_64-linux/ghc-9.6.1/horde-ad-0.1.0.0/l/horde-ad-simplified/noopt/build/horde-ad-simplified/HordeAd/Core/AstInterpret.o, /home/mikolaj/r/horde-ad/dist-newstyle/build/x86_64-linux/ghc-9.6.1/horde-ad-0.1.0.0/l/horde-ad-simplified/noopt/build/horde-ad-simplified/HordeAd/Core/AstInterpret.dyn_o )
<no location info>: error:
panic! (the 'impossible' happened)
GHC version 9.6.1:
ltPSize
Ranked
Call stack:
CallStack (from HasCallStack):
callStackDoc, called at compiler/GHC/Utils/Panic.hs:189:37 in ghc:GHC.Utils.Panic
pprPanic, called at compiler/GHC/Tc/Utils/TcType.hs:2431:5 in ghc:GHC.Tc.Utils.TcType
CallStack (from HasCallStack):
panic, called at compiler/GHC/Utils/Error.hs:454:29 in ghc:GHC.Utils.Error
Please report this as a GHC bug: https://www.haskell.org/ghc/reportabug
Error: cabal: Failed to build lib:horde-ad-simplified from horde-ad-0.1.0.0
(which is required by test:shortTestForCISimplified from horde-ad-0.1.0.0,
test:extremelyLongTestSimplified from horde-ad-0.1.0.0 and others).
This may or may not be related to #23323 (closed)
Steps to reproduce
Compile
https://github.com/Mikolaj/horde-ad/commit/2f463b2d10e697dcccc65bc61633e63e3ea2418d
with cabal build -j1
(adding --allow-newer
for GHC 9.6.1).
Expected behavior
No panic