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 unsizes on mutations #315

Merged
merged 12 commits into from
Nov 2, 2023
Merged

Fix unsizes on mutations #315

merged 12 commits into from
Nov 2, 2023

Conversation

W95Psp
Copy link
Collaborator

@W95Psp W95Psp commented Oct 31, 2023

Fixes #256: copy_from_slice (and any other functions with &mut inputs actually) on sized things (e.g. fixed size arrays [T; N])

This is related to thin / fat pointers.

cc @karthikbhargavan @xvzcf @geonnave

@W95Psp W95Psp force-pushed the fix-unsizes-on-mutations branch from 5c502cf to 77c7c24 Compare October 31, 2023 17:02
Copy link
Member

@franziskuskiefer franziskuskiefer left a comment

Choose a reason for hiding this comment

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

Thanks. Two comments.

I noticed that running tests fails because of js_of_ocaml. This is unrelated to this PR (probably introduced in #265), but something we need to get fixed. Manually installing it fixes the issue

File "bin/dune", line 27, characters 28-39:
27 |  (libraries zarith_stubs_js js_of_ocaml lib))
                                 ^^^^^^^^^^^
Error: Library "js_of_ocaml" not found.

tests/mut-ref-functionalization/src/lib.rs Show resolved Hide resolved
@W95Psp W95Psp force-pushed the fix-unsizes-on-mutations branch from fb1ecbf to 61c4366 Compare November 2, 2023 09:04
@W95Psp
Copy link
Collaborator Author

W95Psp commented Nov 2, 2023

I fixed the field bug, and added the example you suggested @franziskuskiefer :)

@W95Psp W95Psp force-pushed the fix-unsizes-on-mutations branch from 61c4366 to e967a3a Compare November 2, 2023 09:18
@franziskuskiefer
Copy link
Member

I fixed the field bug, and added the example you suggested @franziskuskiefer :)

And you force pushed ... So this will have to wait until tomorrow I'm afraid because I have to start the review from scratch

@W95Psp
Copy link
Collaborator Author

W95Psp commented Nov 2, 2023

Sorry... I'm so used to running git rebase main, but after doing it that's a pain to revert :(

@W95Psp W95Psp force-pushed the fix-unsizes-on-mutations branch 2 times, most recently from 2f367b8 to 2ee26c3 Compare November 2, 2023 13:33
Copy link
Member

@franziskuskiefer franziskuskiefer left a comment

Choose a reason for hiding this comment

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

Thanks

@franziskuskiefer
Copy link
Member

CI is failing

@W95Psp W95Psp force-pushed the fix-unsizes-on-mutations branch from eb456c2 to 8bad5fb Compare November 2, 2023 19:43
@W95Psp W95Psp enabled auto-merge November 2, 2023 19:43
@W95Psp W95Psp added this pull request to the merge queue Nov 2, 2023
Merged via the queue into main with commit ddbc6d6 Nov 2, 2023
9 checks passed
@W95Psp W95Psp deleted the fix-unsizes-on-mutations branch November 2, 2023 20:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

copy_from_slice on a array is not accepted
2 participants