-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Simplify some pointer method implementations #103701
Simplify some pointer method implementations #103701
Conversation
Hey! It looks like you've submitted a new PR for the library teams! If this PR contains changes to any Examples of
|
Looks good to me! Thanks. @bors r+ |
…ation__--this-can-be-simplified, r=scottmcm Simplify some pointer method implementations - Make `pointer::with_metadata_of` const (+simplify implementation) (cc rust-lang#75091) - Simplify implementation of various pointer methods r? `@scottmcm` ---- `from_raw_parts::<T>(this, metadata(self))` was annoying me for a while and I've finally figured out how it should _actually_ be done.
…ation__--this-can-be-simplified, r=scottmcm Simplify some pointer method implementations - Make `pointer::with_metadata_of` const (+simplify implementation) (cc rust-lang#75091) - Simplify implementation of various pointer methods r? ``@scottmcm`` ---- `from_raw_parts::<T>(this, metadata(self))` was annoying me for a while and I've finally figured out how it should _actually_ be done.
…earth Rollup of 8 pull requests Successful merges: - rust-lang#102977 (remove HRTB from `[T]::is_sorted_by{,_key}`) - rust-lang#103378 (Fix mod_inv termination for the last iteration) - rust-lang#103456 (`unchecked_{shl|shr}` should use `u32` as the RHS) - rust-lang#103701 (Simplify some pointer method implementations) - rust-lang#104047 (Diagnostics `icu4x` based list formatting.) - rust-lang#104338 (Enforce that `dyn*` coercions are actually pointer-sized) - rust-lang#104498 (Edit docs for `rustc_errors::Handler::stash_diagnostic`) - rust-lang#104556 (rustdoc: use `code-header` class to format enum variants) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
…jubilee Fix the docs for pointer method with_metadata_of The name of the argument to `{*const T, *mut T}::with_metadata_of` was changed from `val` to `meta` recently, but the docs weren't updated to match. Relevant pull request: rust-lang#103701
pointer::with_metadata_of
const (+simplify implementation) (cc Tracking Issue for [*const T|*mut T]::with_metadata_of #75091)r? @scottmcm
from_raw_parts::<T>(this, metadata(self))
was annoying me for a while and I've finally figured out how it should actually be done.