error-message-index
error-message-index copied to clipboard
Add documentation for GHC-45510
@s-and-witch would you mind checking that the explanation is correct?
This discussion prompted me to submit https://github.com/ghc-proposals/ghc-proposals/pull/656. Check out the updated proposal text and examples, I think it explains quite clearly what's actually happening.
Whatever explanation we end up with for GHC-45510, the main ideas that need to be communicated are
- only out-of-scope type variables are implicitly quantified
- with
RequiredTypeArguments, all variables are in scope in type/kind signatures, regardless of their namespace - but the namespace of a variable is decoupled from whether it's actually a type or term variable, so sometimes we end up with term variables accidentally used in type/kind-level contexts, which triggers GHC-45510
Thanks a lot @s-and-witch and @int-index