Skip to content

Fix ICE in unsafe binder discriminant helpers#154717

Merged
rust-bors[bot] merged 1 commit intorust-lang:mainfrom
cijiugechu:fix/unsafe-binder-discriminant
Apr 6, 2026
Merged

Fix ICE in unsafe binder discriminant helpers#154717
rust-bors[bot] merged 1 commit intorust-lang:mainfrom
cijiugechu:fix/unsafe-binder-discriminant

Conversation

@cijiugechu
Copy link
Copy Markdown
Contributor

@cijiugechu cijiugechu commented Apr 2, 2026

Forward discriminant-related helpers through ty::UnsafeBinder to the erased inner type, matching the existing layout behavior.

Tracking issue: #130516
Closes #154424

Forward discriminant-related queries through `ty::UnsafeBinder` to the erased
inner type, matching the existing layout behavior.
@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Apr 2, 2026
@rustbot
Copy link
Copy Markdown
Collaborator

rustbot commented Apr 2, 2026

r? @jdonszelmann

rustbot has assigned @jdonszelmann.
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: compiler
  • compiler expanded to 69 candidates
  • Random selection from 12 candidates

@cijiugechu cijiugechu changed the title Fix ICE in unsafe binder discriminant queries Fix ICE in unsafe binder discriminant helpers Apr 2, 2026
@jdonszelmann
Copy link
Copy Markdown
Contributor

@bors r+ rollup

@rust-bors
Copy link
Copy Markdown
Contributor

rust-bors bot commented Apr 5, 2026

📌 Commit 3569377 has been approved by jdonszelmann

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 5, 2026
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Apr 5, 2026
…iminant, r=jdonszelmann

Fix ICE in unsafe binder discriminant helpers

Forward discriminant-related helpers through `ty::UnsafeBinder` to the erased inner type, matching the existing layout behavior.

Tracking issue: rust-lang#130516
Closes rust-lang#154424
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Apr 5, 2026
…iminant, r=jdonszelmann

Fix ICE in unsafe binder discriminant helpers

Forward discriminant-related helpers through `ty::UnsafeBinder` to the erased inner type, matching the existing layout behavior.

Tracking issue: rust-lang#130516
Closes rust-lang#154424
rust-bors bot pushed a commit that referenced this pull request Apr 5, 2026
…uwer

Rollup of 8 pull requests

Successful merges:

 - #153440 (Various LTO cleanups)
 - #154561 (Suggest similar keyword when visibility is not followed by an item)
 - #154657 (Fix pattern assignment suggestions for uninitialized bindings)
 - #154717 (Fix ICE in unsafe binder discriminant helpers)
 - #154722 (fix(lints): Improve `ill_formed_attribute_input` with better help message)
 - #154808 (Post-attribute ports cleanup pt. 1)
 - #154849 (Promote `char::is_case_ignorable` from perma-unstable to unstable)
 - #154850 (ast_validation: scalable vectors okay for rustdoc)
rust-bors bot pushed a commit that referenced this pull request Apr 5, 2026
…uwer

Rollup of 8 pull requests

Successful merges:

 - #153440 (Various LTO cleanups)
 - #154561 (Suggest similar keyword when visibility is not followed by an item)
 - #154657 (Fix pattern assignment suggestions for uninitialized bindings)
 - #154717 (Fix ICE in unsafe binder discriminant helpers)
 - #154722 (fix(lints): Improve `ill_formed_attribute_input` with better help message)
 - #154808 (Post-attribute ports cleanup pt. 1)
 - #154849 (Promote `char::is_case_ignorable` from perma-unstable to unstable)
 - #154850 (ast_validation: scalable vectors okay for rustdoc)
rust-bors bot pushed a commit that referenced this pull request Apr 6, 2026
…uwer

Rollup of 8 pull requests

Successful merges:

 - #153440 (Various LTO cleanups)
 - #154561 (Suggest similar keyword when visibility is not followed by an item)
 - #154657 (Fix pattern assignment suggestions for uninitialized bindings)
 - #154717 (Fix ICE in unsafe binder discriminant helpers)
 - #154722 (fix(lints): Improve `ill_formed_attribute_input` with better help message)
 - #154808 (Post-attribute ports cleanup pt. 1)
 - #154849 (Promote `char::is_case_ignorable` from perma-unstable to unstable)
 - #154850 (ast_validation: scalable vectors okay for rustdoc)
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Apr 6, 2026
…iminant, r=jdonszelmann

Fix ICE in unsafe binder discriminant helpers

Forward discriminant-related helpers through `ty::UnsafeBinder` to the erased inner type, matching the existing layout behavior.

Tracking issue: rust-lang#130516
Closes rust-lang#154424
rust-bors bot pushed a commit that referenced this pull request Apr 6, 2026
…uwer

Rollup of 9 pull requests

Successful merges:

 - #153440 (Various LTO cleanups)
 - #151899 (Constify fold, reduce and last for iterator)
 - #154561 (Suggest similar keyword when visibility is not followed by an item)
 - #154657 (Fix pattern assignment suggestions for uninitialized bindings)
 - #154717 (Fix ICE in unsafe binder discriminant helpers)
 - #154722 (fix(lints): Improve `ill_formed_attribute_input` with better help message)
 - #154777 (`#[cfg]`: suggest alternative `target_` name when the value does not match)
 - #154849 (Promote `char::is_case_ignorable` from perma-unstable to unstable)
 - #154850 (ast_validation: scalable vectors okay for rustdoc)
@rust-bors rust-bors bot merged commit a89a5aa into rust-lang:main Apr 6, 2026
11 checks passed
@rustbot rustbot added this to the 1.96.0 milestone Apr 6, 2026
rust-timer added a commit that referenced this pull request Apr 6, 2026
Rollup merge of #154717 - cijiugechu:fix/unsafe-binder-discriminant, r=jdonszelmann

Fix ICE in unsafe binder discriminant helpers

Forward discriminant-related helpers through `ty::UnsafeBinder` to the erased inner type, matching the existing layout behavior.

Tracking issue: #130516
Closes #154424
github-actions bot pushed a commit to rust-lang/miri that referenced this pull request Apr 7, 2026
…uwer

Rollup of 9 pull requests

Successful merges:

 - rust-lang/rust#153440 (Various LTO cleanups)
 - rust-lang/rust#151899 (Constify fold, reduce and last for iterator)
 - rust-lang/rust#154561 (Suggest similar keyword when visibility is not followed by an item)
 - rust-lang/rust#154657 (Fix pattern assignment suggestions for uninitialized bindings)
 - rust-lang/rust#154717 (Fix ICE in unsafe binder discriminant helpers)
 - rust-lang/rust#154722 (fix(lints): Improve `ill_formed_attribute_input` with better help message)
 - rust-lang/rust#154777 (`#[cfg]`: suggest alternative `target_` name when the value does not match)
 - rust-lang/rust#154849 (Promote `char::is_case_ignorable` from perma-unstable to unstable)
 - rust-lang/rust#154850 (ast_validation: scalable vectors okay for rustdoc)
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. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[ICE]: discriminant_for_variant() is None

3 participants