Tc: Allow Typeable in quantified constraints
Previously, when using Typeable in a quantified constraint, GHC would complain that user-specified instances of Typeable aren't allowed. This was because checking for SigmaCtxt was missing from a check for whether an instance head is a hand-written binding. Fixes #20033
Showing
- compiler/GHC/Tc/Validity.hs 1 addition, 0 deletionscompiler/GHC/Tc/Validity.hs
- testsuite/tests/typecheck/should_compile/T20033.hs 17 additions, 0 deletionstestsuite/tests/typecheck/should_compile/T20033.hs
- testsuite/tests/typecheck/should_compile/all.T 1 addition, 0 deletionstestsuite/tests/typecheck/should_compile/all.T
Loading
Please register or sign in to comment