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

Tracking issue for slice_ptr_range #65807

Closed
m-ou-se opened this issue Oct 25, 2019 · 3 comments · Fixed by #77111
Closed

Tracking issue for slice_ptr_range #65807

m-ou-se opened this issue Oct 25, 2019 · 3 comments · Fixed by #77111
Labels
A-raw-pointers Area: raw pointers, MaybeUninit, NonNull A-slice Area: `[T]` B-unstable Blocker: Implemented in the nightly compiler and unstable. C-tracking-issue Category: A tracking issue for an RFC or an unstable feature. Libs-Small Libs issues that are considered "small" or self-contained Libs-Tracked Libs issues that are tracked on the team's project board. requires-nightly This issue requires a nightly compiler in some way. T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.

Comments

@m-ou-se
Copy link
Member

m-ou-se commented Oct 25, 2019

Tracking issue for slice_ptr_range added by #65806. See rust-lang/rfcs#2791

@Centril Centril added T-libs-api Relevant to the library API team, which will review and decide on the PR/issue. B-unstable Blocker: Implemented in the nightly compiler and unstable. requires-nightly This issue requires a nightly compiler in some way. C-tracking-issue Category: A tracking issue for an RFC or an unstable feature. labels Oct 25, 2019
@jhpratt
Copy link
Member

jhpratt commented May 25, 2020

Anything holding up stabilization on this? I'd like to be able to use this to check if two slices overlap, as pointers implement Ord. It seems like a simple API that doesn't have a ton of complexity to it.

@KodrAus KodrAus added A-slice Area: `[T]` I-nominated Libs-Small Libs issues that are considered "small" or self-contained Libs-Tracked Libs issues that are tracked on the team's project board. A-raw-pointers Area: raw pointers, MaybeUninit, NonNull labels Jul 29, 2020
@josephlr
Copy link
Contributor

Note that with #71499 these functions can be made const fn. The stabilization of these methods as const fn can just be tracked as part of #71499.

@m-ou-se
Copy link
Member Author

m-ou-se commented Sep 23, 2020

Note that with #71499 these functions can be made const fn. The stabilization of these methods as const fn can just be tracked as part of #71499.

Thanks! PR: #77097.

Dylan-DPC-zz pushed a commit to Dylan-DPC-zz/rust that referenced this issue Sep 24, 2020
…range-const-fn, r=oli-obk

Make [].as_[mut_]ptr_range() (unstably) const.

Gated behind `const_ptr_offset`, as suggested by rust-lang#65807 (comment)

This also marks `[].as_mut_ptr()` as const, because it's used by `as_mut_ptr_range`. I gated it behind the same feature, because I figured it's not worth adding a separate tracking issue for const `as_mut_ptr`.
RalfJung added a commit to RalfJung/rust that referenced this issue Sep 25, 2020
…range-const-fn, r=oli-obk

Make [].as_[mut_]ptr_range() (unstably) const.

Gated behind `const_ptr_offset`, as suggested by rust-lang#65807 (comment)

This also marks `[].as_mut_ptr()` as const, because it's used by `as_mut_ptr_range`. I gated it behind the same feature, because I figured it's not worth adding a separate tracking issue for const `as_mut_ptr`.
JohnTitor added a commit to JohnTitor/rust that referenced this issue Oct 1, 2020
…slice-ptr-range, r=dtolnay

Stabilize slice_ptr_range.

This has been unstable for almost a year now. Time to stabilize?

Closes rust-lang#65807.

@rustbot modify labels: +T-libs +A-raw-pointers +A-slice +needs-fcp
Dylan-DPC-zz pushed a commit to Dylan-DPC-zz/rust that referenced this issue Oct 1, 2020
…slice-ptr-range, r=dtolnay

Stabilize slice_ptr_range.

This has been unstable for almost a year now. Time to stabilize?

Closes rust-lang#65807.

@rustbot modify labels: +T-libs +A-raw-pointers +A-slice +needs-fcp
@bors bors closed this as completed in f289468 Oct 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-raw-pointers Area: raw pointers, MaybeUninit, NonNull A-slice Area: `[T]` B-unstable Blocker: Implemented in the nightly compiler and unstable. C-tracking-issue Category: A tracking issue for an RFC or an unstable feature. Libs-Small Libs issues that are considered "small" or self-contained Libs-Tracked Libs issues that are tracked on the team's project board. requires-nightly This issue requires a nightly compiler in some way. T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants