-
Notifications
You must be signed in to change notification settings - Fork 12.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do suggest_await_before_try
with infer variables in self, and clean up binders
#97721
Conversation
r? @nagisa (rust-highfive has picked a reviewer for you, use r? to override) |
suggest_await_before_try
with infer variables in self, and clean up binders
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
r=me with or without comment
let projection_ty = trait_pred.map_bound(|trait_pred| { | ||
self.tcx.mk_projection( | ||
item_def_id, | ||
self.tcx.mk_substs_trait(trait_pred.self_ty(), &[]), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Took me a second to realize that the empty list here is fine because it's the future trait; maybe a comment would be helpful?
r? @jackh726 |
6876a88
to
d268b34
Compare
@bors r=jackh726 rollup |
📌 Commit d268b34 has been approved by |
…h726 Do `suggest_await_before_try` with infer variables in self, and clean up binders Fixes rust-lang#97704 Also cleans up binders in this fn, since everything is a `Poly*` and we really shouldn't have stray escaping late-bound regions everywhere. That's why the function changed so much. This isn't necessary, so I can revert if necessary.
…askrgr Rollup of 7 pull requests Successful merges: - rust-lang#90905 (Add empty impl blocks if they have documentation) - rust-lang#97683 (Fail gracefully when encountering an HRTB in APIT. ) - rust-lang#97721 (Do `suggest_await_before_try` with infer variables in self, and clean up binders) - rust-lang#97752 (typo: `-Zcodegen-backend=llvm -Cpasses=list` should work now) - rust-lang#97759 (Suggest adding `{}` for `'label: non_block_expr`) - rust-lang#97764 (use strict provenance APIs) - rust-lang#97765 (Restore a test that was intended to test `as` cast to ptr) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Fixes #97704
Also cleans up binders in this fn, since everything is a
Poly*
and we really shouldn't have stray escaping late-bound regions everywhere. That's why the function changed so much. This isn't necessary, so I can revert if necessary.