Skip to content
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

Propagate coercions through match expressions. #19769

Merged
merged 1 commit into from
Dec 18, 2014
Merged

Conversation

nrc
Copy link
Member

@nrc nrc commented Dec 12, 2014

r? @nikomatsakis

We discussed coercions for if and match expressions. if seems to work already, was there some specific behaviour which wasn't working?

@nikomatsakis
Copy link
Contributor

afaik if does not work, we can discuss on IRC though

@nikomatsakis
Copy link
Contributor

"truly" propagating coercions means more than just propagating expections, is part of it...

@nikomatsakis
Copy link
Contributor

So @nick29581 and I discussed on IRC and it seems that i'm a bit out of date, and we now use the expectation to drive coercion sometimes, particularly in ExprBlock scenarios.

@nikomatsakis
Copy link
Contributor

r+ though I'd like to know what's going on with ()

bors added a commit that referenced this pull request Dec 18, 2014
r? @nikomatsakis 

We discussed coercions for `if` and `match` expressions. `if` seems to work already, was there some specific behaviour which wasn't working?
@bors bors merged commit 46eb724 into rust-lang:master Dec 18, 2014
@lilyball
Copy link
Contributor

It seems this PR introduced #20055, a failure in run-pass/coerce-match.rs that reproduces 100% of the time for me on OS X 10.10.

@lilyball
Copy link
Contributor

And of course this PR is the one that introduced run-pass/coerce-match.rs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants