Skip to content

Try just disallowing widening of abstract types #16206

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

dwijnand
Copy link
Member

No description provided.

@dwijnand dwijnand changed the title Try just disallowing allowing widening abstract types Try just disallowing widening of abstract types Oct 18, 2022
@dwijnand dwijnand force-pushed the match-types-completeness branch from 0bc377d to 4c63583 Compare October 19, 2022 06:41
@dwijnand dwijnand force-pushed the match-types-completeness branch from 4c63583 to f616cae Compare October 19, 2022 07:31
@odersky
Copy link
Contributor

odersky commented Oct 19, 2022

We can try this to get more info, but it's almost certainly not the correct solution. We need to be able to widen abstract types. It makes no sense to disallow it since it would violate narrowing.

@dwijnand dwijnand linked an issue Oct 20, 2022 that may be closed by this pull request
@dwijnand dwijnand self-assigned this Oct 24, 2022
@dwijnand
Copy link
Member Author

Reviewing this with Guillaume this is in a complicated state where we can't tell what is unsound and therefore whether the test expectation changes here are fixes or regressions. So we leave maybe unsound code compile and make reasonable code like #15926 not compile? 😞

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3.2.0 regression around match types
2 participants