|
We've been flip-flopping on this one through the years, right
now we issue an two errors for the enclosed test.
After this commit, variance validation only expands aliases that
are `{private,protected}[this]`. The rest need not be expanded,
as we have already variance validated the RHS of the alias.
It also removes a seemingly incorrect check in `isLocalOnly`.
This also means that we can use `@uncheckedVariance` to create
variant type aliases for Java interfaces.
However, if such a type alias is declared private local, it
*will* be expanded. That shouldn't be a problem, other than
for the fact that we run through an as-seen-from that strips
the `@uV` annotations in the type expansion. This has been
recorded in a pending test.
|