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

[stdlib] Add static method InlineArray.unsafe_uninitialized() #3122

Open
wants to merge 7 commits into
base: nightly
Choose a base branch
from

Conversation

gabrieldemarmiesse
Copy link
Contributor

@gabrieldemarmiesse gabrieldemarmiesse commented Jun 25, 2024

This requires #3119 to be merged first.

Note that I would like this method to be in the future UnlineArray[UnsafeMaybeUninitialized[...], ...]() in the future, but we currently have no way to verify that the generic type of the elements is UnsafeMaybeUninitialized so that will have to wait.

I'm not sure if this PR is fully correct. Is it okay to work with pointers on uninitialized data like this? Maybe the code was already wrong to begin with?

@ConnorGray for review as you are the one following the work in this area.

@gabrieldemarmiesse gabrieldemarmiesse changed the title [stdlib] Add a unsafe_assume_initialized constructor to InlineArray [stdlib] Add static method InlineArray.unsafe_uninitialized() Jun 25, 2024
@gabrieldemarmiesse gabrieldemarmiesse marked this pull request as ready for review June 25, 2024 20:49
@gabrieldemarmiesse gabrieldemarmiesse requested a review from a team as a code owner June 25, 2024 20:49
@ConnorGray ConnorGray self-assigned this Jun 25, 2024
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.

None yet

2 participants