Conversation
|
r? @davidtwco (rust-highfive has picked a reviewer for you, use r? to override) |
|
This isn't the right fix for this. Roughly, when we see an impl like So, our final See #85477 for a previous (abandoned) attempt at this. And my comment for solutions. I think probably the simplest option is either to 1) Check if the self ty is an error as in #85477 2) Treat this lifetime as Here is resolve lifetime in scope for an impl. Interestingly, we are storing late-bound lifetimes here but probably shouldn't be. (You can try to remove that line and see if anything fails; would be good to know.) But, we can probably add a |
|
r? @jackh726 |
|
Thanks for the great review I was not happy with the fix itself 😅 , I will try to implement new solution as you suggested. |
|
Let me know if you have questions. I'm around on Zulip most of the time. |
There was a problem hiding this comment.
This can just be in the same match arm as Scope::ObjectLifetimeDefault etc.
There was a problem hiding this comment.
How ? Scope::ObjectLifetimeDefault does a completely different thing, that would cause an infinite loop I think.
jackh726
left a comment
There was a problem hiding this comment.
Sorry, just a couple more things! Also, can you squash the commits?
|
@bors r+ |
|
📌 Commit be566f1 has been approved by |
…askrgr Rollup of 6 pull requests Successful merges: - rust-lang#95074 (Refactor: use `format-args-capture` and remove unnecessary nested if blocks in some parts of `rust_passes`) - rust-lang#95085 (Return err instead of ICE) - rust-lang#95116 (Add needs-* directives to many tests) - rust-lang#95129 (Remove animation on source sidebar) - rust-lang#95166 (Update the unstable book with the new `values()` form of check-cfg) - rust-lang#95175 (move `adt_const_params` to its own tracking issue) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Having
escaping_bound_varsresults in ICE when trying to createty::Binder::dummy, to avoid it we return err like the line above. I think this requires a more sophisticated fix, I would love to investigate if mentorship is available 🤓Fixes #95023 and #85350