Skip to content

Fix classify_union to return Union for regular unions#155690

Merged
rust-bors[bot] merged 1 commit intorust-lang:mainfrom
fneddy:fix_classify_union
Apr 24, 2026
Merged

Fix classify_union to return Union for regular unions#155690
rust-bors[bot] merged 1 commit intorust-lang:mainfrom
fneddy:fix_classify_union

Conversation

@fneddy
Copy link
Copy Markdown
Contributor

@fneddy fneddy commented Apr 23, 2026

Commit 623c7d7 accidentally changed the return value from REGULAR_UNION to RegularEnum when converting string literals to enum values. Commit b17670d then renamed RegularUnion to Union, but the buggy return statement remained unchanged. This caused unions to be misclassified as enums, preventing LLDB from displaying union field contents.

Commit 623c7d7 accidentally changed the return value from
REGULAR_UNION to RegularEnum when converting string literals
to enum values. Commit b17670d then renamed RegularUnion
to Union, but the buggy return statement remained unchanged.
This caused unions to be misclassified as enums, preventing
LLDB from displaying union field contents.
@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Apr 23, 2026
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Apr 23, 2026

r? @Mark-Simulacrum

rustbot has assigned @Mark-Simulacrum.
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

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: @Mark-Simulacrum

Copy link
Copy Markdown
Member

@jieyouxu jieyouxu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks
r? me @bors r+ rollup

View changes since this review

@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors Bot commented Apr 23, 2026

📌 Commit 2f99ab1 has been approved by jieyouxu

It is now in the queue for this repository.

@rust-bors rust-bors Bot 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 Apr 23, 2026
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Apr 23, 2026
Fix classify_union to return Union for regular unions

Commit 623c7d7 accidentally changed the return value from REGULAR_UNION to RegularEnum when converting string literals to enum values. Commit b17670d then renamed RegularUnion to Union, but the buggy return statement remained unchanged. This caused unions to be misclassified as enums, preventing LLDB from displaying union field contents.
rust-bors Bot pushed a commit that referenced this pull request Apr 23, 2026
…uwer

Rollup of 7 pull requests

Successful merges:

 - #155621 (Document #[diagnostic::on_move] in the unstable book.)
 - #155671 (Simplify `Config::track_state`.)
 - #153482 (tests/ui/macros: add annotations for reference rules)
 - #155075 (Add docs about SDKs and C compilation on armv7a-vex-v5)
 - #155685 (Fix `get_child_at_index` return type hints)
 - #155686 (Fix array template arg lookup behavior)
 - #155690 (Fix classify_union to return Union for regular unions)
rust-bors Bot pushed a commit that referenced this pull request Apr 24, 2026
Rollup of 7 pull requests

Successful merges:

 - #155660 (c-variadic: fix for sparc64)
 - #153482 (tests/ui/macros: add annotations for reference rules)
 - #155075 (Add docs about SDKs and C compilation on armv7a-vex-v5)
 - #155685 (Fix `get_child_at_index` return type hints)
 - #155686 (Fix array template arg lookup behavior)
 - #155689 (Const initialize `LOCK_LATCH` thread local)
 - #155690 (Fix classify_union to return Union for regular unions)
@rust-bors rust-bors Bot merged commit 2493328 into rust-lang:main Apr 24, 2026
11 checks passed
rust-timer added a commit that referenced this pull request Apr 24, 2026
Rollup merge of #155690 - fneddy:fix_classify_union, r=jieyouxu

Fix classify_union to return Union for regular unions

Commit 623c7d7 accidentally changed the return value from REGULAR_UNION to RegularEnum when converting string literals to enum values. Commit b17670d then renamed RegularUnion to Union, but the buggy return statement remained unchanged. This caused unions to be misclassified as enums, preventing LLDB from displaying union field contents.
@rustbot rustbot added this to the 1.97.0 milestone Apr 24, 2026
github-actions Bot pushed a commit to rust-lang/rustc-dev-guide that referenced this pull request Apr 24, 2026
Rollup of 7 pull requests

Successful merges:

 - rust-lang/rust#155660 (c-variadic: fix for sparc64)
 - rust-lang/rust#153482 (tests/ui/macros: add annotations for reference rules)
 - rust-lang/rust#155075 (Add docs about SDKs and C compilation on armv7a-vex-v5)
 - rust-lang/rust#155685 (Fix `get_child_at_index` return type hints)
 - rust-lang/rust#155686 (Fix array template arg lookup behavior)
 - rust-lang/rust#155689 (Const initialize `LOCK_LATCH` thread local)
 - rust-lang/rust#155690 (Fix classify_union to return Union for regular unions)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants