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

Sema: convert slice sentinel to single pointer correctly #23221

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Rexicon226
Copy link
Contributor

If the src_ty is a [:0]const u8, the single pointer would try to inherit the sentinel, which is invalid. I've fixed it to move the sentinel to the child type, if there is one, and then clear the sentinel from the pointer info we're inheriting.

@Rexicon226 Rexicon226 force-pushed the comptime-memcpy-fix branch from 39bc17f to 09cbba3 Compare March 12, 2025 22:54
@Rexicon226 Rexicon226 force-pushed the comptime-memcpy-fix branch from 09cbba3 to cbcd772 Compare March 13, 2025 01:14
@alexrp
Copy link
Member

alexrp commented Mar 13, 2025

Is this a 0.14.1 candidate? (i.e. a non-breaking bug fix)

@Rexicon226
Copy link
Contributor Author

This is nonbreaking, these types never leave the implementation.

@alexrp alexrp added this to the 0.14.1 milestone Mar 13, 2025
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.

2 participants