Skip to content

Fix issue #36036. - #36281

Merged
bors merged 1 commit into
rust-lang:masterfrom
pnkfelix:fix-issue-36036
Sep 5, 2016
Merged

Fix issue #36036.#36281
bors merged 1 commit into
rust-lang:masterfrom
pnkfelix:fix-issue-36036

Conversation

@pnkfelix

Copy link
Copy Markdown
Contributor

Fix#36036.

We were treating an associated type as unsized even when the concrete instantiation was actually sized. Fix is to normalize before checking if it is sized.

@rust-highfive

Copy link
Copy Markdown
Contributor

r? @nikomatsakis

(rust_highfive has picked a reviewer for you, use r? to override)

@pnkfelix

Copy link
Copy Markdown
ContributorAuthor

r? @eddyb

if pointee.is_sized(tcx, &infcx.parameter_environment, DUMMY_SP) {
Scalar { value: Pointer, non_zero: non_zero }
} else {
let pointee = normalize_associated_type(infcx, pointee);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh I didn't realize this line was already there, that makes the fix clearer.

@eddyb

eddyb commented Sep 5, 2016

Copy link
Copy Markdown
Contributor

@bors r+

@bors

bors commented Sep 5, 2016

Copy link
Copy Markdown
Collaborator

📌 Commit 09e6a98 has been approved by eddyb

We were treating an associated type as unsized even when the concrete
instantiation was actually sized. Fix is to normalize before checking
if it is sized.
@bors

bors commented Sep 5, 2016

Copy link
Copy Markdown
Collaborator

⌛ Testing commit 09e6a98 with merge 38824d1...

bors added a commit that referenced this pull request Sep 5, 2016
Fix issue #36036.
Fix#36036.
We were treating an associated type as unsized even when the concrete instantiation was actually sized. Fix is to normalize before checking if it is sized.
@bors
bors merged commit 09e6a98 into rust-lang:masterSep 5, 2016
@pnkfelixpnkfelix added the beta-nominated Nominated for backporting to the compiler in the beta channel. label Sep 8, 2016
@nikomatsakis

Copy link
Copy Markdown
Contributor

Seems like a clear case for beta-accepted: one line, fairly trivial change, fixes regression. Marking it as such.

cc @rust-lang/compiler

@nikomatsakisnikomatsakis added the beta-accepted Accepted for backporting to the compiler in the beta channel. label Sep 13, 2016
@brsonbrson mentioned this pull request Sep 16, 2016
@brsonbrson removed the beta-nominated Nominated for backporting to the compiler in the beta channel. label Sep 19, 2016
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

beta-acceptedAccepted for backporting to the compiler in the beta channel.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants

@pnkfelix@rust-highfive@eddyb@bors@nikomatsakis@brson