Skip to content

Conversation

Gankra
Copy link
Contributor

@Gankra Gankra commented Mar 3, 2024

This is an API that naturally should exist as a combination of byte_offset_from and sub_ptr both existing (they showed up at similar times so this union was never made). Adding these is a logical (and perhaps final) precondition of stabilizing ptr_sub_ptr (#95892).

This is an API that naturally should exist as a combination of byte_offset_from and sub_ptr
both existing (they showed up at similar times so this union was never made). Adding these
is a logical (and perhaps final) precondition of stabilizing ptr_sub_ptr (rust-lang#95892).
@rustbot
Copy link
Collaborator

rustbot commented Mar 3, 2024

r? @m-ou-se

rustbot has assigned @m-ou-se.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Mar 3, 2024
@cuviper cuviper added T-libs-api Relevant to the library API team, which will review and decide on the PR/issue. and removed T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Mar 29, 2024
@scottmcm
Copy link
Member

Given the precedents from the existing byte_* methods, I think it's fine to add this in nightly without needing the ceremony of an ACP.

r? scottmcm
@bors r+ rollup

@bors
Copy link
Collaborator

bors commented May 29, 2024

📌 Commit d42d678 has been approved by scottmcm

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 29, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request May 29, 2024
feat(byte_sub_ptr): add ptr::byte_sub_ptr

This is an API that naturally should exist as a combination of byte_offset_from and sub_ptr both existing (they showed up at similar times so this union was never made). Adding these is a logical (and perhaps final) precondition of stabilizing ptr_sub_ptr (rust-lang#95892).
@bors
Copy link
Collaborator

bors commented May 29, 2024

⌛ Testing commit d42d678 with merge 9d03362...

@rust-log-analyzer
Copy link
Collaborator

The job dist-powerpc-linux failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)

error[E0711]: feature `non_null_convenience` is declared unstable, but was previously declared stable
   --> library/core/src/ptr/non_null.rs:964:5
    |
964 |     #[rustc_const_unstable(feature = "non_null_convenience", issue = "117691")]

For more information about this error, try `rustc --explain E0711`.
[RUSTC-TIMING] core test:false 6.701
error: could not compile `core` (lib) due to 2 previous errors

@bors
Copy link
Collaborator

bors commented May 29, 2024

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels May 29, 2024
fmease added a commit to fmease/rust that referenced this pull request May 30, 2024
feat(byte_sub_ptr): add ptr::byte_sub_ptr

This is an API that naturally should exist as a combination of byte_offset_from and sub_ptr both existing (they showed up at similar times so this union was never made). Adding these is a logical (and perhaps final) precondition of stabilizing ptr_sub_ptr (rust-lang#95892).
@fmease
Copy link
Member

fmease commented May 30, 2024

@bors r-

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 30, 2024
@bors
Copy link
Collaborator

bors commented Jul 6, 2024

☔ The latest upstream changes (presumably #127420) made this pull request unmergeable. Please resolve the merge conflicts.

@JohnCSimon
Copy link
Member

JohnCSimon commented Sep 4, 2024

@Gankra
ping from triage - can you post your status on this PR? This PR has not received an update in a few months. There are test failures and conflicts

@alex-semenyuk alex-semenyuk added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Oct 29, 2024
@RalfJung
Copy link
Member

RalfJung commented Nov 1, 2024

I have rebased the PR and reposted it as #132459. Thanks @Gankra for initially authoring it!

@RalfJung RalfJung closed this Nov 1, 2024
jieyouxu added a commit to jieyouxu/rust that referenced this pull request Nov 1, 2024
feat(byte_sub_ptr): unstably add ptr::byte_sub_ptr

This is an API that naturally should exist as a combination of byte_offset_from and sub_ptr
both existing (they showed up at similar times so this union was never made). Adding these
is a logical (and perhaps final) precondition of stabilizing ptr_sub_ptr (rust-lang#95892).

Original PR by `@Gankra` (rust-lang#121919), I am just reviving it. The 2nd commit (with a small docs tweak) is by me.
GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Nov 1, 2024
feat(byte_sub_ptr): unstably add ptr::byte_sub_ptr

This is an API that naturally should exist as a combination of byte_offset_from and sub_ptr
both existing (they showed up at similar times so this union was never made). Adding these
is a logical (and perhaps final) precondition of stabilizing ptr_sub_ptr (rust-lang#95892).

Original PR by ``@Gankra`` (rust-lang#121919), I am just reviving it. The 2nd commit (with a small docs tweak) is by me.
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Nov 2, 2024
Rollup merge of rust-lang#132459 - RalfJung:byte_sub_ptr, r=scottmcm

feat(byte_sub_ptr): unstably add ptr::byte_sub_ptr

This is an API that naturally should exist as a combination of byte_offset_from and sub_ptr
both existing (they showed up at similar times so this union was never made). Adding these
is a logical (and perhaps final) precondition of stabilizing ptr_sub_ptr (rust-lang#95892).

Original PR by ``@Gankra`` (rust-lang#121919), I am just reviving it. The 2nd commit (with a small docs tweak) is by me.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-libs-api Relevant to the library API team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.