Skip to content
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

Fix edge case for intersection between virtual metaclasses #11185

Conversation

HertzDevil
Copy link
Contributor

Follow-up to #11121. Fixes a regression on master where the following no longer worked:

class A
end

class B < A
end

A.as(A.class) # Unhandled exception: cast from Class to A+.class failed

@HertzDevil HertzDevil added kind:bug kind:regression Something that used to correctly work but no longer works topic:compiler:semantic labels Sep 8, 2021
Copy link
Member

@asterite asterite left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@HertzDevil HertzDevil added this to the 1.2.0 milestone Sep 9, 2021
@straight-shoota straight-shoota merged commit 4a59481 into crystal-lang:master Sep 11, 2021
@HertzDevil HertzDevil deleted the bug/virtual-metaclass-intersect branch September 12, 2021 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind:bug kind:regression Something that used to correctly work but no longer works topic:compiler:semantic
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants