-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Stabilize const_slice_split_at_mut
and const_slice_first_last_chunk
#130428
Stabilize const_slice_split_at_mut
and const_slice_first_last_chunk
#130428
Conversation
Failed to set assignee to
|
734f16b
to
aee1cdd
Compare
This comment has been minimized.
This comment has been minimized.
Cc @rust-lang/wg-const-eval |
☔ The latest upstream changes (presumably #130738) made this pull request unmergeable. Please resolve the merge conflicts. |
@onestacked Could you remove the TODO and fix this up so it can be merged after the other PR lands? We usually just tag PRs as |
@workingjubilee I'll wait until the FCP is done, to avoid having to rebase again and again. |
If you want you can include stabilizing #111774 in this PR as well, as it depends on the feature here and the two went into FCP together. Given the amount of feature gates moving towards stabilization, there's no reason to have an individual PR for each of them. :) |
const_slice_split_at_mut
const_slice_split_at_mut
and slice_first_last_chunk
const_slice_split_at_mut
and slice_first_last_chunk
const_slice_split_at_mut
and const_slice_first_last_chunk
aee1cdd
to
949a4da
Compare
This comment has been minimized.
This comment has been minimized.
949a4da
to
5a6b0d1
Compare
This comment has been minimized.
This comment has been minimized.
Thank you! |
5a6b0d1
to
6d29b66
Compare
This comment has been minimized.
This comment has been minimized.
☔ The latest upstream changes (presumably #131269) made this pull request unmergeable. Please resolve the merge conflicts. |
Both FCPs have passed, so this is ready to go. @onestacked can you resolve the conflicts? |
6d29b66
to
d0e6758
Compare
r=me when CI is green. @bors delegate+ |
✌️ @onestacked, you can now approve this pull request! If @RalfJung told you to " |
@bors rollup |
…iaskrgr Rollup of 5 pull requests Successful merges: - rust-lang#130428 (Stabilize `const_slice_split_at_mut` and `const_slice_first_last_chunk`) - rust-lang#131094 (std: replace `LazyBox` with `OnceBox`) - rust-lang#131256 (move f16/f128 const fn under f16/f128 feature gate) - rust-lang#131278 (remove outdated contribution direction) - rust-lang#131286 (Miri subtree update) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#130428 - ink-feather-org:stabilize-const-split-at-mut, r=RalfJung Stabilize `const_slice_split_at_mut` and `const_slice_first_last_chunk` Stabilizes rust-lang#101804 and the remainder of rust-lang#111774. FCP proposed in the tracking issue. Requires rust-lang#130403 (or it would need a rustc_allow_const_fn_unstable for it) Stabilized const API: ```rust // slice impl [T] { pub const fn split_at_mut(&mut self, mid: usize) -> (&mut [T], &mut [T]); pub const fn split_at_mut_unchecked(&mut self, mid: usize) -> (&mut [T], &mut [T]); pub const fn split_at_mut_checked(&mut self, mid: usize) -> Option<(&mut [T], &mut [T])>; pub const fn first_chunk_mut<const N: usize>(&mut self) -> Option<&mut [T; N]>; pub const fn last_chunk_mut<const N: usize>(&mut self) -> Option<&mut [T; N]>; pub const fn split_first_chunk_mut<const N: usize>(&mut self) -> Option<(&mut [T; N], &mut [T])>; pub const fn split_last_chunk_mut<const N: usize>(&mut self) -> Option<(&mut [T; N], &mut [T])>; } ``` Closes rust-lang#101804 Closes rust-lang#111774 cc `@RalfJung`
Stabilizes #101804 and the remainder of #111774.
FCP proposed in the tracking issue.
Requires #130403 (or it would need a rustc_allow_const_fn_unstable for it)
Stabilized const API:
Closes #101804
Closes #111774
cc @RalfJung