Skip to content

Do not consider match/let/ref of place that evaluates to ! to diverge, disallow coercions from them too#18278

Merged
bors merged 1 commit into
rust-lang:masterfrom
ShoyuVanilla:never-place
Oct 15, 2024
Merged

Do not consider match/let/ref of place that evaluates to ! to diverge, disallow coercions from them too#18278
bors merged 1 commit into
rust-lang:masterfrom
ShoyuVanilla:never-place

Conversation

@ShoyuVanilla

Copy link
Copy Markdown
Member

Resolves #18237

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Oct 10, 2024
"#]],
)
}

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

We should have a test that make type mismatch error without this PR, but it doesn't emit the error, either with or without this PR.
https://github.com/rust-lang/rust/pull/129392/files#r1746775782
I'll address it as a new issue

"#,
);
}

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

These tests are all of the tests that included in the rustc's original PR, except one case (commented below) and mir ones

Comment thread crates/hir-ty/src/infer/coerce.rs Outdated
Comment thread crates/hir-ty/src/infer/expr.rs Outdated
@Veykril

Veykril commented Oct 15, 2024

Copy link
Copy Markdown
Member

@bors r+

@bors

bors commented Oct 15, 2024

Copy link
Copy Markdown
Contributor

📌 Commit 91293ea has been approved by Veykril

It is now in the queue for this repository.

@bors

bors commented Oct 15, 2024

Copy link
Copy Markdown
Contributor

⌛ Testing commit 91293ea with merge 418c136...

@bors

bors commented Oct 15, 2024

Copy link
Copy Markdown
Contributor

☀️ Test successful - checks-actions
Approved by: Veykril
Pushing 418c136 to master...

1 similar comment
@bors

bors commented Oct 15, 2024

Copy link
Copy Markdown
Contributor

☀️ Test successful - checks-actions
Approved by: Veykril
Pushing 418c136 to master...

@bors bors merged commit 418c136 into rust-lang:master Oct 15, 2024
@bors

bors commented Oct 15, 2024

Copy link
Copy Markdown
Contributor

👀 Test was successful, but fast-forwarding failed: 422 Changes must be made through a pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Do not consider match/let/ref of place that evaluates to ! to diverge, disallow coercions from them too

4 participants