Implement the -Wimplicit-rhs-quantification warning
GHC Proposal #425 "Invisible binders in type declarations" forbids implicit quantification of type variables that occur free on the right-hand side of a type synonym but are not mentioned on the left-hand side. The users are expected to rewrite this using invisible binders:
type T1 = 'Nothing :: Maybe a -- old
type T1 @a = 'Nothing :: Maybe a -- new
Since the @k
-binders are a new feature, we need to wait for three releases before we require the use of the new syntax. In the meantime, we ought to provide users with a new warning, -Wimplicit-rhs-quantification
, that would detect when such implicit quantification takes place, and include it in -Wcompat
.
This ticket is to track the implementation of the warning.