Literal string redundantly abstracted over a type variable
Summary
(I have no idea what's happening, but GHC asks me to report a bug)
Steps to reproduce
sorry, didn't have time to minimize
git clone https://git.imn.htwk-leipzig.de/waldmann/autotool.git
cd autotool
git submodule init
git submodule update
curl https://ghc.gitlab.haskell.org/head.hackage/cabal.project >> cabal.project.local
cabal update
cabal build -w /opt/ghc/ghc-9.10.0.20240313/bin/ghc transport
Observed behaviour
...
<no location info>: error:
panic! (the 'impossible' happened)
GHC version 9.10.0.20240313:
corePrepPgm
Case lzy-ctx _x_r3oD :: forall {atom}. Addr#
[GblId, Unf=OtherCon []]
_x_r3oD = \ (@atom_a2ge) -> "missing"#
Call stack:
CallStack (from HasCallStack):
callStackDoc, called at compiler/GHC/Utils/Panic.hs:190:37 in ghc-9.10.0.20240313-inplace:GHC.Utils.Panic
pprPanic, called at compiler/GHC/CoreToStg/Prep.hs:2050:16 in ghc-9.10.0.20240313-inplace:GHC.CoreToStg.Prep
CallStack (from HasCallStack):
panic, called at compiler/GHC/Utils/Error.hs:507:29 in ghc-9.10.0.20240313-inplace:GHC.Utils.Error
Please report this as a GHC bug: https://www.haskell.org/ghc/reportabug
Note
error does NOT happen with -O0
, or -O2
, but DOES appear with -O1
(which is cabal's default?)