LUB of a bivariant parameter is not fully general #41044
Labels
C-bug
Category: This is a bug.
I-needs-decision
Issue: In need of a decision.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
In #40570, I removed bivariance somewhat aggressively. One area where we are not quite doing the right thing, it appears, is when computing the LUB/GLB of a bivariant type parameter. The code currently just picks one side, which seems clearly wrong, but I was not able to craft a test case exploiting that. Therefore, opening an issue to revisit later if we can get a concrete test case.
This comment explains my preferred fix:
The text was updated successfully, but these errors were encountered: