Make PolyTraitRef::self_ty return Binder<Ty>#72508
Merged
bors merged 2 commits intorust-lang:masterfrom Jun 7, 2020
Merged
Conversation
Contributor
Author
PolyTraitPredicate::self_ty return Binder<Ty>PolyTraitRef::self_ty return Binder<Ty>
| pub fn self_ty(&self) -> Ty<'tcx> { | ||
| self.skip_binder().self_ty() | ||
| pub fn self_ty(&self) -> Binder<Ty<'tcx>> { | ||
| self.map_bound_ref(|tr| tr.self_ty()) |
nikomatsakis
approved these changes
May 26, 2020
| Some(format!( | ||
| "`?` couldn't convert the error to `{}`", | ||
| trait_ref.self_ty(), | ||
| trait_ref.skip_binder().self_ty(), |
Contributor
There was a problem hiding this comment.
"Less yay" -- this seems ok for now I guess but I wish we had a different solution than skipping the binder
Contributor
|
@bors r+ |
Collaborator
|
📌 Commit 09cd547 has been approved by |
Dylan-DPC-zz
pushed a commit
to Dylan-DPC-zz/rust
that referenced
this pull request
May 27, 2020
…matsakis Make `PolyTraitRef::self_ty` return `Binder<Ty>` This came up during review of rust-lang#71618. The current implementation is the same as a call to `skip_binder` but harder to audit. Make it preserve binding levels and add a call to `skip_binder` at all use sites so they can be audited as part of rust-lang#72507.
|
failed in rollup ci check @bors r- |
09cd547 to
b4e06b9
Compare
Contributor
Author
|
@bors retry |
Contributor
Author
|
@bors r=nikomatsakis |
Collaborator
|
📌 Commit b4e06b9 has been approved by |
Collaborator
|
⌛ Testing commit b4e06b9 with merge 0372fd6c280a1a0b743a22403c39bb95daebf364... |
|
@bors retry yield |
Dylan-DPC-zz
pushed a commit
to Dylan-DPC-zz/rust
that referenced
this pull request
Jun 5, 2020
…matsakis Make `PolyTraitRef::self_ty` return `Binder<Ty>` This came up during review of rust-lang#71618. The current implementation is the same as a call to `skip_binder` but harder to audit. Make it preserve binding levels and add a call to `skip_binder` at all use sites so they can be audited as part of rust-lang#72507.
Dylan-DPC-zz
pushed a commit
to Dylan-DPC-zz/rust
that referenced
this pull request
Jun 5, 2020
…matsakis Make `PolyTraitRef::self_ty` return `Binder<Ty>` This came up during review of rust-lang#71618. The current implementation is the same as a call to `skip_binder` but harder to audit. Make it preserve binding levels and add a call to `skip_binder` at all use sites so they can be audited as part of rust-lang#72507.
Member
|
Could this have caused #73043 (comment)? I can't see a direct connection, and the panic unfortunately doesn't have a useful line number, but the other changes in that rollup seem even less likely to be the culprit. |
Member
|
Hm, probably it's not this one, as #73053 has the same failure. |
RalfJung
added a commit
to RalfJung/rust
that referenced
this pull request
Jun 6, 2020
…matsakis Make `PolyTraitRef::self_ty` return `Binder<Ty>` This came up during review of rust-lang#71618. The current implementation is the same as a call to `skip_binder` but harder to audit. Make it preserve binding levels and add a call to `skip_binder` at all use sites so they can be audited as part of rust-lang#72507.
RalfJung
added a commit
to RalfJung/rust
that referenced
this pull request
Jun 6, 2020
…matsakis Make `PolyTraitRef::self_ty` return `Binder<Ty>` This came up during review of rust-lang#71618. The current implementation is the same as a call to `skip_binder` but harder to audit. Make it preserve binding levels and add a call to `skip_binder` at all use sites so they can be audited as part of rust-lang#72507.
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Jun 6, 2020
Rollup of 3 pull requests Successful merges: - rust-lang#71796 (de-promote Duration::from_secs) - rust-lang#72508 (Make `PolyTraitRef::self_ty` return `Binder<Ty>`) - rust-lang#72708 (linker: Add a linker rerun hack for gcc versions not supporting -static-pie) Failed merges: r? @ghost
tesuji
pushed a commit
to tesuji/rustc
that referenced
this pull request
Jun 9, 2020
…matsakis Make `PolyTraitRef::self_ty` return `Binder<Ty>` This came up during review of rust-lang#71618. The current implementation is the same as a call to `skip_binder` but harder to audit. Make it preserve binding levels and add a call to `skip_binder` at all use sites so they can be audited as part of rust-lang#72507.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This came up during review of #71618. The current implementation is the same as a call to
skip_binderbut harder to audit. Make it preserve binding levels and add a call toskip_binderat all use sites so they can be audited as part of #72507.