-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
Rollup of 4 pull requests #138551
Rollup of 4 pull requests #138551
Conversation
Because `.as_ptr()` changes the type of the pointer (e.g. `&[u8]` becomes `*const u8` instead of `*const [u8]`), and it can't be expected that different types will be formatted the same way.
Co-authored-by: Lukas <26522220+lukas-code@users.noreply.github.com>
Make Rust pointers less magic by including metadata information in their `Debug` output. This does not break Rust stability guarantees because `Debug` output is explicitly exempted from stability: https://doc.rust-lang.org/std/fmt/trait.Debug.html#stability Co-authored-by: Lukas <26522220+lukas-code@users.noreply.github.com> Co-authored-by: Josh Stone <cuviper@gmail.com>
core: Make `Debug` impl of raw pointers print metadata if present Make Rust pointers appear less magic by including metadata information in their `Debug` output. This does not break Rust stability guarantees because `Debug` impl are explicitly exempted from stability: https://doc.rust-lang.org/std/fmt/trait.Debug.html#stability > ## Stability > > Derived `Debug` formats are not stable, and so may change with future Rust versions. Additionally, `Debug` implementations of types provided by the standard library (`std`, `core`, `alloc`, etc.) are not stable, and may also change with future Rust versions. Note that a regression test is added as a separate commit to make it clear what impact the last commit has on the output. Closes rust-lang#128684 because the output of that code now becomes: ``` thread 'main' panicked at src/main.rs:5:5: assertion `left == right` failed left: Pointer { addr: 0x7ffd45c6fc6b, metadata: 5 } right: Pointer { addr: 0x7ffd45c6fc6b, metadata: 3 } note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace ```
libstd: rustdoc: correct note on fds 0/1/2 pre-main Closes: rust-lang#137490
fix doc path in std::fmt macro fixes rust-lang#137519
Fix the OperandRef type for NullOp::{UbChecks,ContractChecks} Stumbled on this while looking at something totally unrelated 🙃 r? saethlin
@bors r+ rollup=never p=5 |
☀️ Test successful - checks-actions |
📌 Perf builds for each rolled up PR:
previous master: 5f3b84a421 In the case of a perf regression, run the following command for each PR you suspect might be the cause: |
This is an experimental post-merge analysis report. You can ignore it. Post-merge reportComparing 5f3b84a (base) -> d497e43 (this PR) Test differences
Additionally, 4 doctest diffs were found. These are ignored, as they are noisy. Job group index
|
Finished benchmarking commit (d497e43): comparison URL. Overall result: no relevant changes - no action needed@rustbot label: -perf-regression Instruction countThis benchmark run did not return any relevant results for this metric. Max RSS (memory usage)Results (primary 2.8%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResults (primary -2.3%)This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 775.444s -> 775.874s (0.06%) |
Successful merges:
Debug
impl of raw pointers print metadata if present #135080 (core: MakeDebug
impl of raw pointers print metadata if present)r? @ghost
@rustbot modify labels: rollup
Create a similar rollup