Don't use isUnliftedType in isTagged
The function GHC.Stg.InferTags.Rewrite.isTagged can be given the Id of a join point, which might be representation polymorphic. This would cause the call to isUnliftedType to crash. It's better to use typeLevity_maybe instead. Fixes #22212
Showing
- compiler/GHC/Stg/InferTags/Rewrite.hs 10 additions, 5 deletionscompiler/GHC/Stg/InferTags/Rewrite.hs
- testsuite/tests/simplStg/should_compile/T22212.hs 45 additions, 0 deletionstestsuite/tests/simplStg/should_compile/T22212.hs
- testsuite/tests/simplStg/should_compile/all.T 2 additions, 0 deletionstestsuite/tests/simplStg/should_compile/all.T
Loading
Please register or sign in to comment