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 undefined behavior in interpreter mixed union upcast #15042

Conversation

HertzDevil
Copy link
Contributor

Fixes #15041.

It also changes the move_to in the tuple indexers to move_from, although in practice these don't exhibit unexpected behavior, because most memcpy implementations copy data from lower addresses to higher addresses, and these calls move data to a lower address.

@HertzDevil HertzDevil added kind:bug A bug in the code. Does not apply to documentation, specs, etc. topic:compiler:interpreter labels Sep 26, 2024
@straight-shoota straight-shoota added this to the 1.14.0 milestone Sep 27, 2024
@straight-shoota straight-shoota merged commit 7aeba1e into crystal-lang:master Sep 28, 2024
65 checks passed
@HertzDevil HertzDevil deleted the bug/interpreter-mixed-union-upcast branch October 2, 2024 05:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind:bug A bug in the code. Does not apply to documentation, specs, etc. topic:compiler:interpreter
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Mixed union upcast is broken in interpreter on Alpine Linux
4 participants