Properly handle Pin<&mut dyn* Trait> receiver in codegen#104594
Properly handle Pin<&mut dyn* Trait> receiver in codegen#104594bors merged 3 commits intorust-lang:masterfrom
Pin<&mut dyn* Trait> receiver in codegen#104594Conversation
|
r? @estebank (rustbot has picked a reviewer for you, use r? to override) |
|
☔ The latest upstream changes (presumably #104533) made this pull request unmergeable. Please resolve the merge conflicts. |
There was a problem hiding this comment.
I'm uncomfortable leaving this commented out.
There was a problem hiding this comment.
Are you asking for it to be deleted instead? Because I can do that.
There was a problem hiding this comment.
Surprised by this removal
There was a problem hiding this comment.
I see the more specific pattern here and in the next file, but doesn't this code have to run for non dyn*?
There was a problem hiding this comment.
Can you be more specific? Did you see the PR description that mentions "Also, disable dyn* trait upcasting"?
Because all this disables is CoerceUnsized implementations from dyn* Trait to dyn* SuperTrait, which cannot be implemented with CoerceUnsized and need to be reworked.
There was a problem hiding this comment.
I see. r=me after rebasing
src/test/ui/dyn-star/upcast.rs
Outdated
There was a problem hiding this comment.
I can file a bug for this.
estebank
left a comment
There was a problem hiding this comment.
The changes look reasonable, but might there be someone already involved in dyn* that can double check?
r? @eholk |
eholk
left a comment
There was a problem hiding this comment.
Looks good to me. I added a couple small comments or questions, but I think merging as-is is fine, so r=me if you're ready.
src/test/ui/dyn-star/upcast.rs
Outdated
d8cb8c3 to
b60b76c
Compare
|
@bors r=eholk,estebank |
…iaskrgr Rollup of 9 pull requests Successful merges: - rust-lang#103908 (Suggest `.clone()` or `ref binding` on E0382) - rust-lang#104517 (Throw error on failure in loading llvm-plugin) - rust-lang#104594 (Properly handle `Pin<&mut dyn* Trait>` receiver in codegen) - rust-lang#104742 (Make `deref_into_dyn_supertrait` lint the impl and not the usage) - rust-lang#104753 (Pass `InferCtxt` to `DropRangeVisitor` so we can resolve vars) - rust-lang#104771 (Add regression test for issue rust-lang#99938) - rust-lang#104772 (Small accessibility improvements) - rust-lang#104775 (Use ObligationCtxt::normalize) - rust-lang#104778 (:arrow_up: rust-analyzer) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
This ensures we can actually await a
dyn* Future, which seems important for async fn in dyn trait.Also, disable
dyn*trait upcasting. It's not exactly complete right now, and can cause strange ICEs for no reason -- nobody's using it either. I thought it was cute to implement when I did it, but I didn't think about how it interacts structurally withCoerceUnsizedcorrectly.Fixes #104794, presumably removing
dyn*upcasting and itsCoerceUnsizedissues does the trick.