Uh oh!
There was an error while loading. Please reload this page.
Do not attempt to ascribe projections out of a ty var - #55637
Conversation
rust-highfive
commented
Nov 3, 2018
r? @varkor (rust_highfive has picked a reviewer for you, use r? to override) |
pnkfelix
commented
Nov 3, 2018
| self, | ||
| tcx: TyCtxt<'a, 'gcx, 'tcx>, | ||
| elem: &ProjectionElem<'tcx, V, T>, | ||
| mut handle_field: impl FnMut(&Self, &Field, &T) -> Result<Ty<'tcx>, E>) |
There was a problem hiding this comment.
Nit: rustfmt would put the ) on the next line.
nikomatsakis
commented
Nov 6, 2018
@bors r+ |
bors
commented
Nov 6, 2018
📌 Commit 1bbaa55 has been approved by |
nikomatsakis
commented
Nov 6, 2018
@pnkfelix and I were discussing this PR and we observed that it could cause problems if you have repeated type variables, e.g., |
pnkfelix
commented
Nov 8, 2018
discussed at T-compiler meeting. beta-accepting (with a wee bit of trepidation from @nagisa ) |
emilyalbini
commented
Nov 9, 2018
@bors p=1 (beta accepted) |
bors
commented
Nov 9, 2018
⌛ Testing commit 1bbaa55 with merge 041e18f00bcde960a131884b391f59a077a6b5a3... |
bors
commented
Nov 9, 2018
💔 Test failed - status-appveyor |
pnkfelix
commented
Nov 9, 2018
... that message ... sounds like a spurious failure to me ...? |
pnkfelix
commented
Nov 9, 2018
@bors r+ |
bors
commented
Nov 9, 2018
💡 This pull request was already approved, no need to approve it again.
|
bors
commented
Nov 9, 2018
📌 Commit 1bbaa55 has been approved by |
pnkfelix
commented
Nov 9, 2018
@bors r=nikomatsakis |
bors
commented
Nov 9, 2018
💡 This pull request was already approved, no need to approve it again.
|
bors
commented
Nov 9, 2018
📌 Commit 1bbaa55 has been approved by |
pnkfelix
commented
Nov 9, 2018
@bors retry |
pnkfelix
commented
Nov 9, 2018
@bors p=1 (beta accepted) |
| let mut projected_ty = PlaceTy::from_ty(ty); | ||
| let ty = self.normalize(ty, locations); | ||
| // We need to follow any provided projetions into the type. |
There was a problem hiding this comment.
| // We need to follow any provided projetions into the type. | |
| // We need to follow any provided projections into the type. |
| let ty = self.normalize(ty); | ||
| let mut projected_ty = PlaceTy::from_ty(ty); | ||
| // We need to follow any provided projetions into the type. |
There was a problem hiding this comment.
| // We need to follow any provided projetions into the type. | |
| // We need to follow any provided projections into the type. |
| // rust-lang/rust#55552: The strategy pnkfelix landed in PR #55274 | ||
| // (for ensuring that NLL respects user-provided lifetime annotations) | ||
| // did not handle the case where the ascribed type has some expliit |
There was a problem hiding this comment.
| // did not handle the case where the ascribed type has some expliit | |
| // did not handle the case where the ascribed type has some explicit |
bors
commented
Nov 10, 2018
…rojections-out-of-a-ty-var, r=nikomatsakis Do not attempt to ascribe projections out of a ty var If we encounter `_` ascribed to structural pattern like `(a, b)`, just skip relate_types. Fix#55552
bors
commented
Nov 10, 2018
☀️ Test successful - status-appveyor, status-travis |
If we encounter
_ascribed to structural pattern like(a, b), just skip relate_types.Fix#55552