Repository navigation
[debuginfo] Emit usize and isize as typedefs - #163104
Merged
Merged
Conversation
Collaborator
|
r? @chenyukang rustbot has assigned @chenyukang. Use Why was this reviewer chosen?The reviewer was selected based on:
|
Member
|
@rustbot reroll |
Contributor
Author
|
(#163098 means i need to modify the tests again before this gets merged) |
mati865
approved these changes
Oct 5, 2026
Walnut356
force-pushed
the
i_usize_typedef
branch
from
October 6, 2026 06:00
8b131a4 to
7f38840
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Walnut356
force-pushed
the
i_usize_typedef
branch
from
October 20, 2026 08:49
7f38840 to
de1d7d2
Compare
Collaborator
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
Walnut356
force-pushed
the
i_usize_typedef
branch
from
October 20, 2026 09:01
de1d7d2 to
0370417
Compare
Member
|
Sorry, I missed the rebase. @bors r+ |
Contributor
JonathanBrouwer
added a commit
to JonathanBrouwer/rust
that referenced
this pull request
Oct 20, 2026
[debuginfo] Emit `usize` and `isize` as typedefs See: llvm/llvm-project#196812 TL;DR sidesteps a name collision issue that affects generics, e.g. `S<u64>` and `S<usize>` resolving as the same type. This is accomplished by wrapping an existing primitive node in a `usize`/`isize` typedef instead. I'd love to output typedefs for all the primitive types too, so LLDB displays the type names rust-style, but I've got a couple worries with that. Firstly, GDB doesn't seem to like it w.r.t. enums? IIRC it's because of a small difference in how GDB treats typedefs compared to LLDB. I'm like 80% sure it's hard-coded in GDB itself, so it's not something I want to touch atm. ``` Breakpoint 1, borrowed_enum::main () at tests/debuginfo/borrowed-enum.rs:67 67 zzz(); // #break $1 = <error reading variable: Could not find active enum variant> $2 = borrowed_enum::ABC::TheB(0, 286331153, 286331153) $3 = borrowed_enum::Univariant::TheOnlyCase(4820353753753434) ``` Secondly, I'm not entirely sure it's a good idea to have both a type and a typedef with the exact same name in the first place. I could easily imagine that causing some similar issues to the one we're trying to solve. This also includes a small extention to the `Rc` test to ensure we can read both `Rc<u64>` and `Rc<usize>`. Without this change, the second `v` command would fail to materialize any value: ``` ... (lldb) v rc_u64 (alloc::rc::Rc<unsigned long, alloc::alloc::Global>) rc_u64 = strong=1, weak=0 { value = 10 } (lldb) v rc_usize error: Invalid type: Cannot determine size (lldb) quit ```
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 20, 2026
…uwer Rollup of 6 pull requests Successful merges: - #163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - #164488 (Don't try to skip anything in `Skip::advance_by(0)`) - #164578 (Don't ignore unknown LLVM diagnostics) - #164611 (Improve bit permutation codegen) - #162668 (document that `!` does bitwise and logical negation) - #164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons)
JonathanBrouwer
added a commit
to JonathanBrouwer/rust
that referenced
this pull request
Oct 20, 2026
[debuginfo] Emit `usize` and `isize` as typedefs See: llvm/llvm-project#196812 TL;DR sidesteps a name collision issue that affects generics, e.g. `S<u64>` and `S<usize>` resolving as the same type. This is accomplished by wrapping an existing primitive node in a `usize`/`isize` typedef instead. I'd love to output typedefs for all the primitive types too, so LLDB displays the type names rust-style, but I've got a couple worries with that. Firstly, GDB doesn't seem to like it w.r.t. enums? IIRC it's because of a small difference in how GDB treats typedefs compared to LLDB. I'm like 80% sure it's hard-coded in GDB itself, so it's not something I want to touch atm. ``` Breakpoint 1, borrowed_enum::main () at tests/debuginfo/borrowed-enum.rs:67 67 zzz(); // #break $1 = <error reading variable: Could not find active enum variant> $2 = borrowed_enum::ABC::TheB(0, 286331153, 286331153) $3 = borrowed_enum::Univariant::TheOnlyCase(4820353753753434) ``` Secondly, I'm not entirely sure it's a good idea to have both a type and a typedef with the exact same name in the first place. I could easily imagine that causing some similar issues to the one we're trying to solve. This also includes a small extention to the `Rc` test to ensure we can read both `Rc<u64>` and `Rc<usize>`. Without this change, the second `v` command would fail to materialize any value: ``` ... (lldb) v rc_u64 (alloc::rc::Rc<unsigned long, alloc::alloc::Global>) rc_u64 = strong=1, weak=0 { value = 10 } (lldb) v rc_usize error: Invalid type: Cannot determine size (lldb) quit ```
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 20, 2026
…uwer Rollup of 14 pull requests Successful merges: - #163575 (core: Add examples and assembly tests for `abort_immediate`) - #163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - #163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - #163338 (MIR move elimination [4/6]: MoveElimination) - #163701 (add ReadDir::dir to get the directory handle of the underlying directory) - #164488 (Don't try to skip anything in `Skip::advance_by(0)`) - #164578 (Don't ignore unknown LLVM diagnostics) - #164611 (Improve bit permutation codegen) - #164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - #162668 (document that `!` does bitwise and logical negation) - #164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - #164509 (layout invariant: turn delayed bug back into proper assertion) - #164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - #164629 (arch::breakpoint: avoid confusing 'equivalent' terminology)
JonathanBrouwer
added a commit
to JonathanBrouwer/rust
that referenced
this pull request
Oct 20, 2026
[debuginfo] Emit `usize` and `isize` as typedefs See: llvm/llvm-project#196812 TL;DR sidesteps a name collision issue that affects generics, e.g. `S<u64>` and `S<usize>` resolving as the same type. This is accomplished by wrapping an existing primitive node in a `usize`/`isize` typedef instead. I'd love to output typedefs for all the primitive types too, so LLDB displays the type names rust-style, but I've got a couple worries with that. Firstly, GDB doesn't seem to like it w.r.t. enums? IIRC it's because of a small difference in how GDB treats typedefs compared to LLDB. I'm like 80% sure it's hard-coded in GDB itself, so it's not something I want to touch atm. ``` Breakpoint 1, borrowed_enum::main () at tests/debuginfo/borrowed-enum.rs:67 67 zzz(); // #break $1 = <error reading variable: Could not find active enum variant> $2 = borrowed_enum::ABC::TheB(0, 286331153, 286331153) $3 = borrowed_enum::Univariant::TheOnlyCase(4820353753753434) ``` Secondly, I'm not entirely sure it's a good idea to have both a type and a typedef with the exact same name in the first place. I could easily imagine that causing some similar issues to the one we're trying to solve. This also includes a small extention to the `Rc` test to ensure we can read both `Rc<u64>` and `Rc<usize>`. Without this change, the second `v` command would fail to materialize any value: ``` ... (lldb) v rc_u64 (alloc::rc::Rc<unsigned long, alloc::alloc::Global>) rc_u64 = strong=1, weak=0 { value = 10 } (lldb) v rc_usize error: Invalid type: Cannot determine size (lldb) quit ```
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 20, 2026
…uwer Rollup of 13 pull requests Successful merges: - #163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - #163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - #163338 (MIR move elimination [4/6]: MoveElimination) - #163701 (add ReadDir::dir to get the directory handle of the underlying directory) - #164488 (Don't try to skip anything in `Skip::advance_by(0)`) - #164578 (Don't ignore unknown LLVM diagnostics) - #164611 (Improve bit permutation codegen) - #164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - #162668 (document that `!` does bitwise and logical negation) - #164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - #164509 (layout invariant: turn delayed bug back into proper assertion) - #164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - #164629 (arch::breakpoint: avoid confusing 'equivalent' terminology)
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 20, 2026
…uwer Rollup of 13 pull requests Successful merges: - #163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - #163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - #163338 (MIR move elimination [4/6]: MoveElimination) - #163701 (add ReadDir::dir to get the directory handle of the underlying directory) - #164488 (Don't try to skip anything in `Skip::advance_by(0)`) - #164578 (Don't ignore unknown LLVM diagnostics) - #164611 (Improve bit permutation codegen) - #164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - #162668 (document that `!` does bitwise and logical negation) - #164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - #164509 (layout invariant: turn delayed bug back into proper assertion) - #164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - #164629 (arch::breakpoint: avoid confusing 'equivalent' terminology)
JonathanBrouwer
added a commit
to JonathanBrouwer/rust
that referenced
this pull request
Oct 20, 2026
[debuginfo] Emit `usize` and `isize` as typedefs See: llvm/llvm-project#196812 TL;DR sidesteps a name collision issue that affects generics, e.g. `S<u64>` and `S<usize>` resolving as the same type. This is accomplished by wrapping an existing primitive node in a `usize`/`isize` typedef instead. I'd love to output typedefs for all the primitive types too, so LLDB displays the type names rust-style, but I've got a couple worries with that. Firstly, GDB doesn't seem to like it w.r.t. enums? IIRC it's because of a small difference in how GDB treats typedefs compared to LLDB. I'm like 80% sure it's hard-coded in GDB itself, so it's not something I want to touch atm. ``` Breakpoint 1, borrowed_enum::main () at tests/debuginfo/borrowed-enum.rs:67 67 zzz(); // #break $1 = <error reading variable: Could not find active enum variant> $2 = borrowed_enum::ABC::TheB(0, 286331153, 286331153) $3 = borrowed_enum::Univariant::TheOnlyCase(4820353753753434) ``` Secondly, I'm not entirely sure it's a good idea to have both a type and a typedef with the exact same name in the first place. I could easily imagine that causing some similar issues to the one we're trying to solve. This also includes a small extention to the `Rc` test to ensure we can read both `Rc<u64>` and `Rc<usize>`. Without this change, the second `v` command would fail to materialize any value: ``` ... (lldb) v rc_u64 (alloc::rc::Rc<unsigned long, alloc::alloc::Global>) rc_u64 = strong=1, weak=0 { value = 10 } (lldb) v rc_usize error: Invalid type: Cannot determine size (lldb) quit ```
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 20, 2026
…uwer Rollup of 15 pull requests Successful merges: - #163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - #163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - #163338 (MIR move elimination [4/6]: MoveElimination) - #163701 (add ReadDir::dir to get the directory handle of the underlying directory) - #164488 (Don't try to skip anything in `Skip::advance_by(0)`) - #164611 (Improve bit permutation codegen) - #164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - #148842 (Avoid incorrect lifetime suggestion involving `sym::anon`) - #162668 (document that `!` does bitwise and logical negation) - #164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - #164509 (layout invariant: turn delayed bug back into proper assertion) - #164540 (Minor optimizations around macro parsing) - #164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - #164595 (Allow attributes in function trait parameters) - #164629 (arch::breakpoint: avoid confusing 'equivalent' terminology)
JonathanBrouwer
added a commit
to JonathanBrouwer/rust
that referenced
this pull request
Oct 20, 2026
[debuginfo] Emit `usize` and `isize` as typedefs See: llvm/llvm-project#196812 TL;DR sidesteps a name collision issue that affects generics, e.g. `S<u64>` and `S<usize>` resolving as the same type. This is accomplished by wrapping an existing primitive node in a `usize`/`isize` typedef instead. I'd love to output typedefs for all the primitive types too, so LLDB displays the type names rust-style, but I've got a couple worries with that. Firstly, GDB doesn't seem to like it w.r.t. enums? IIRC it's because of a small difference in how GDB treats typedefs compared to LLDB. I'm like 80% sure it's hard-coded in GDB itself, so it's not something I want to touch atm. ``` Breakpoint 1, borrowed_enum::main () at tests/debuginfo/borrowed-enum.rs:67 67 zzz(); // #break $1 = <error reading variable: Could not find active enum variant> $2 = borrowed_enum::ABC::TheB(0, 286331153, 286331153) $3 = borrowed_enum::Univariant::TheOnlyCase(4820353753753434) ``` Secondly, I'm not entirely sure it's a good idea to have both a type and a typedef with the exact same name in the first place. I could easily imagine that causing some similar issues to the one we're trying to solve. This also includes a small extention to the `Rc` test to ensure we can read both `Rc<u64>` and `Rc<usize>`. Without this change, the second `v` command would fail to materialize any value: ``` ... (lldb) v rc_u64 (alloc::rc::Rc<unsigned long, alloc::alloc::Global>) rc_u64 = strong=1, weak=0 { value = 10 } (lldb) v rc_usize error: Invalid type: Cannot determine size (lldb) quit ```
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 20, 2026
…uwer Rollup of 14 pull requests Successful merges: - #163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - #163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - #163701 (add ReadDir::dir to get the directory handle of the underlying directory) - #164488 (Don't try to skip anything in `Skip::advance_by(0)`) - #164611 (Improve bit permutation codegen) - #164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - #148842 (Avoid incorrect lifetime suggestion involving `sym::anon`) - #162668 (document that `!` does bitwise and logical negation) - #164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - #164509 (layout invariant: turn delayed bug back into proper assertion) - #164540 (Minor optimizations around macro parsing) - #164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - #164595 (Allow attributes in function trait parameters) - #164629 (arch::breakpoint: avoid confusing 'equivalent' terminology)
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 20, 2026
…uwer Rollup of 14 pull requests Successful merges: - #163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - #163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - #163701 (add ReadDir::dir to get the directory handle of the underlying directory) - #164488 (Don't try to skip anything in `Skip::advance_by(0)`) - #164611 (Improve bit permutation codegen) - #164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - #148842 (Avoid incorrect lifetime suggestion involving `sym::anon`) - #162668 (document that `!` does bitwise and logical negation) - #164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - #164509 (layout invariant: turn delayed bug back into proper assertion) - #164540 (Minor optimizations around macro parsing) - #164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - #164595 (Allow attributes in function trait parameters) - #164629 (arch::breakpoint: avoid confusing 'equivalent' terminology)
JonathanBrouwer
added a commit
to JonathanBrouwer/rust
that referenced
this pull request
Oct 20, 2026
[debuginfo] Emit `usize` and `isize` as typedefs See: llvm/llvm-project#196812 TL;DR sidesteps a name collision issue that affects generics, e.g. `S<u64>` and `S<usize>` resolving as the same type. This is accomplished by wrapping an existing primitive node in a `usize`/`isize` typedef instead. I'd love to output typedefs for all the primitive types too, so LLDB displays the type names rust-style, but I've got a couple worries with that. Firstly, GDB doesn't seem to like it w.r.t. enums? IIRC it's because of a small difference in how GDB treats typedefs compared to LLDB. I'm like 80% sure it's hard-coded in GDB itself, so it's not something I want to touch atm. ``` Breakpoint 1, borrowed_enum::main () at tests/debuginfo/borrowed-enum.rs:67 67 zzz(); // #break $1 = <error reading variable: Could not find active enum variant> $2 = borrowed_enum::ABC::TheB(0, 286331153, 286331153) $3 = borrowed_enum::Univariant::TheOnlyCase(4820353753753434) ``` Secondly, I'm not entirely sure it's a good idea to have both a type and a typedef with the exact same name in the first place. I could easily imagine that causing some similar issues to the one we're trying to solve. This also includes a small extention to the `Rc` test to ensure we can read both `Rc<u64>` and `Rc<usize>`. Without this change, the second `v` command would fail to materialize any value: ``` ... (lldb) v rc_u64 (alloc::rc::Rc<unsigned long, alloc::alloc::Global>) rc_u64 = strong=1, weak=0 { value = 10 } (lldb) v rc_usize error: Invalid type: Cannot determine size (lldb) quit ```
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 20, 2026
…uwer Rollup of 19 pull requests Successful merges: - #163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - #163668 (Remap syntax contexts and expansion ids for det. metadata encoding) - #160404 (fd-views: AsRef<File>&Co. for BorrowedFd) - #163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - #163317 (Stop useless caching of post-LTO artifact caching for fat LTO) - #163701 (add ReadDir::dir to get the directory handle of the underlying directory) - #164488 (Don't try to skip anything in `Skip::advance_by(0)`) - #164507 (Encode HashMap and HashSet in deterministic order when an encoder requires determinism) - #164611 (Improve bit permutation codegen) - #164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - #148842 (Avoid incorrect lifetime suggestion involving `sym::anon`) - #162668 (document that `!` does bitwise and logical negation) - #164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - #164509 (layout invariant: turn delayed bug back into proper assertion) - #164540 (Minor optimizations around macro parsing) - #164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - #164595 (Allow attributes in function trait parameters) - #164641 (Stabilize `slice_split_once`) - #164646 (Adjust rustfmt subtree sync docs to not use `--allow-noop` for now)
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 21, 2026
Rollup of 20 pull requests Successful merges: - #163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - #163668 (Remap syntax contexts and expansion ids for det. metadata encoding) - #163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - #163317 (Stop useless caching of post-LTO artifact caching for fat LTO) - #163701 (add ReadDir::dir to get the directory handle of the underlying directory) - #164488 (Don't try to skip anything in `Skip::advance_by(0)`) - #164507 (Encode HashMap and HashSet in deterministic order when an encoder requires determinism) - #164611 (Improve bit permutation codegen) - #164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - #148842 (Avoid incorrect lifetime suggestion involving `sym::anon`) - #162668 (document that `!` does bitwise and logical negation) - #164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - #164509 (layout invariant: turn delayed bug back into proper assertion) - #164540 (Minor optimizations around macro parsing) - #164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - #164595 (Allow attributes in function trait parameters) - #164616 (Add test for VecDeque with a custom allocator) - #164629 (arch::breakpoint: avoid confusing 'equivalent' terminology) - #164641 (Stabilize `slice_split_once`) - #164646 (Adjust rustfmt subtree sync docs to not use `--allow-noop` for now)
rust-bors Bot
pushed a commit
that referenced
this pull request
Oct 21, 2026
Rollup merge of #163104 - Walnut356:i_usize_typedef, r=mati865 [debuginfo] Emit `usize` and `isize` as typedefs See: llvm/llvm-project#196812 TL;DR sidesteps a name collision issue that affects generics, e.g. `S<u64>` and `S<usize>` resolving as the same type. This is accomplished by wrapping an existing primitive node in a `usize`/`isize` typedef instead. I'd love to output typedefs for all the primitive types too, so LLDB displays the type names rust-style, but I've got a couple worries with that. Firstly, GDB doesn't seem to like it w.r.t. enums? IIRC it's because of a small difference in how GDB treats typedefs compared to LLDB. I'm like 80% sure it's hard-coded in GDB itself, so it's not something I want to touch atm. ``` Breakpoint 1, borrowed_enum::main () at tests/debuginfo/borrowed-enum.rs:67 67 zzz(); // #break $1 = <error reading variable: Could not find active enum variant> $2 = borrowed_enum::ABC::TheB(0, 286331153, 286331153) $3 = borrowed_enum::Univariant::TheOnlyCase(4820353753753434) ``` Secondly, I'm not entirely sure it's a good idea to have both a type and a typedef with the exact same name in the first place. I could easily imagine that causing some similar issues to the one we're trying to solve. This also includes a small extention to the `Rc` test to ensure we can read both `Rc<u64>` and `Rc<usize>`. Without this change, the second `v` command would fail to materialize any value: ``` ... (lldb) v rc_u64 (alloc::rc::Rc<unsigned long, alloc::alloc::Global>) rc_u64 = strong=1, weak=0 { value = 10 } (lldb) v rc_usize error: Invalid type: Cannot determine size (lldb) quit ```
github-actions Bot
pushed a commit
to rust-lang/stdarch
that referenced
this pull request
Oct 22, 2026
Rollup of 20 pull requests Successful merges: - rust-lang/rust#163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - rust-lang/rust#163668 (Remap syntax contexts and expansion ids for det. metadata encoding) - rust-lang/rust#163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - rust-lang/rust#163317 (Stop useless caching of post-LTO artifact caching for fat LTO) - rust-lang/rust#163701 (add ReadDir::dir to get the directory handle of the underlying directory) - rust-lang/rust#164488 (Don't try to skip anything in `Skip::advance_by(0)`) - rust-lang/rust#164507 (Encode HashMap and HashSet in deterministic order when an encoder requires determinism) - rust-lang/rust#164611 (Improve bit permutation codegen) - rust-lang/rust#164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - rust-lang/rust#148842 (Avoid incorrect lifetime suggestion involving `sym::anon`) - rust-lang/rust#162668 (document that `!` does bitwise and logical negation) - rust-lang/rust#164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - rust-lang/rust#164509 (layout invariant: turn delayed bug back into proper assertion) - rust-lang/rust#164540 (Minor optimizations around macro parsing) - rust-lang/rust#164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - rust-lang/rust#164595 (Allow attributes in function trait parameters) - rust-lang/rust#164616 (Add test for VecDeque with a custom allocator) - rust-lang/rust#164629 (arch::breakpoint: avoid confusing 'equivalent' terminology) - rust-lang/rust#164641 (Stabilize `slice_split_once`) - rust-lang/rust#164646 (Adjust rustfmt subtree sync docs to not use `--allow-noop` for now)
jieyouxu
pushed a commit
to jieyouxu/rustfmt
that referenced
this pull request
Oct 22, 2026
Rollup of 20 pull requests Successful merges: - rust-lang/rust#163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - rust-lang/rust#163668 (Remap syntax contexts and expansion ids for det. metadata encoding) - rust-lang/rust#163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - rust-lang/rust#163317 (Stop useless caching of post-LTO artifact caching for fat LTO) - rust-lang/rust#163701 (add ReadDir::dir to get the directory handle of the underlying directory) - rust-lang/rust#164488 (Don't try to skip anything in `Skip::advance_by(0)`) - rust-lang/rust#164507 (Encode HashMap and HashSet in deterministic order when an encoder requires determinism) - rust-lang/rust#164611 (Improve bit permutation codegen) - rust-lang/rust#164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - rust-lang/rust#148842 (Avoid incorrect lifetime suggestion involving `sym::anon`) - rust-lang/rust#162668 (document that `!` does bitwise and logical negation) - rust-lang/rust#164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - rust-lang/rust#164509 (layout invariant: turn delayed bug back into proper assertion) - rust-lang/rust#164540 (Minor optimizations around macro parsing) - rust-lang/rust#164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - rust-lang/rust#164595 (Allow attributes in function trait parameters) - rust-lang/rust#164616 (Add test for VecDeque with a custom allocator) - rust-lang/rust#164629 (arch::breakpoint: avoid confusing 'equivalent' terminology) - rust-lang/rust#164641 (Stabilize `slice_split_once`) - rust-lang/rust#164646 (Adjust rustfmt subtree sync docs to not use `--allow-noop` for now)
programskillforverification
pushed a commit
to programskillforverification/miri
that referenced
this pull request
Oct 22, 2026
Rollup of 20 pull requests Successful merges: - rust-lang/rust#163664 (Add new `RUSTC_BOOTSTRAP=-allow-unstable-compiler-flags` mode for testing stable compiler behavior in UI tests) - rust-lang/rust#163668 (Remap syntax contexts and expansion ids for det. metadata encoding) - rust-lang/rust#163104 ([debuginfo] Emit `usize` and `isize` as typedefs) - rust-lang/rust#163317 (Stop useless caching of post-LTO artifact caching for fat LTO) - rust-lang/rust#163701 (add ReadDir::dir to get the directory handle of the underlying directory) - rust-lang/rust#164488 (Don't try to skip anything in `Skip::advance_by(0)`) - rust-lang/rust#164507 (Encode HashMap and HashSet in deterministic order when an encoder requires determinism) - rust-lang/rust#164611 (Improve bit permutation codegen) - rust-lang/rust#164612 (std: Combine `is_powerpc64_feature_detected` into `is_powerpc_feature_detected`) - rust-lang/rust#148842 (Avoid incorrect lifetime suggestion involving `sym::anon`) - rust-lang/rust#162668 (document that `!` does bitwise and logical negation) - rust-lang/rust#164264 (lint: suggest `fXX::is_nan` for unsuffixed NaN comparisons) - rust-lang/rust#164509 (layout invariant: turn delayed bug back into proper assertion) - rust-lang/rust#164540 (Minor optimizations around macro parsing) - rust-lang/rust#164594 (rustdoc: Correctly handle inner `deprecated` attribute on modules) - rust-lang/rust#164595 (Allow attributes in function trait parameters) - rust-lang/rust#164616 (Add test for VecDeque with a custom allocator) - rust-lang/rust#164629 (arch::breakpoint: avoid confusing 'equivalent' terminology) - rust-lang/rust#164641 (Stabilize `slice_split_once`) - rust-lang/rust#164646 (Adjust rustfmt subtree sync docs to not use `--allow-noop` for now)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See: llvm/llvm-project#196812
TL;DR sidesteps a name collision issue that affects generics, e.g.
S<u64>andS<usize>resolving as the same type.This is accomplished by wrapping an existing primitive node in a
usize/isizetypedef instead.I'd love to output typedefs for all the primitive types too, so LLDB displays the type names rust-style, but I've got a couple worries with that. Firstly, GDB doesn't seem to like it w.r.t. enums? IIRC it's because of a small difference in how GDB treats typedefs compared to LLDB. I'm like 80% sure it's hard-coded in GDB itself, so it's not something I want to touch atm.
Secondly, I'm not entirely sure it's a good idea to have both a type and a typedef with the exact same name in the first place. I could easily imagine that causing some similar issues to the one we're trying to solve.
This also includes a small extention to the
Rctest to ensure we can read bothRc<u64>andRc<usize>. Without this change, the secondvcommand would fail to materialize any value: