DmdAnal: Don't panic in addCaseBndrDmd (#22039)
Rather conservatively return Top. See Note [Untyped demand on case-alternative binders]. I also factored `addCaseBndrDmd` into two separate functions `scrutSubDmd` and `fieldBndrDmds`. Fixes #22039.
Showing
- compiler/GHC/Core/Opt/DmdAnal.hs 57 additions, 18 deletionscompiler/GHC/Core/Opt/DmdAnal.hs
- testsuite/tests/stranal/should_compile/T22039.hs 59 additions, 0 deletionstestsuite/tests/stranal/should_compile/T22039.hs
- testsuite/tests/stranal/should_compile/all.T 1 addition, 0 deletionstestsuite/tests/stranal/should_compile/all.T
Loading
Please register or sign in to comment