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

don't display duplicate trait errors #28645

Merged
merged 2 commits into from
Sep 28, 2015

Conversation

arielb1
Copy link
Contributor

@arielb1 arielb1 commented Sep 24, 2015

more info in the individual commits

r? @nikomatsakis

@bors
Copy link
Contributor

bors commented Sep 25, 2015

☔ The latest upstream changes (presumably #28608) made this pull request unmergeable. Please resolve the merge conflicts.

@bors
Copy link
Contributor

bors commented Sep 26, 2015

☔ The latest upstream changes (presumably #28629) made this pull request unmergeable. Please resolve the merge conflicts.

Ariel Ben-Yehuda added 2 commits September 26, 2015 21:13
Because of type inference, duplicate obligations exist and cause duplicate
errors. To avoid this, only display the first error for each (predicate,span).

The inclusion of the span is somewhat bikesheddy, but *is* the more
conservative option (it does not remove some instability, as duplicate
obligations are ignored by `duplicate_set` under some inference conditions).

Fixes rust-lang#28098
cc rust-lang#21528 (is it a dupe?)
different supertraits can suffer from the same object-safety violation,
leading to duplication in the error message. Avoid it.

Fixes rust-lang#20692
@alexcrichton alexcrichton merged commit 346088b into rust-lang:master Sep 28, 2015
@brson brson added the relnotes Marks issues that should be documented in the release notes of the next release. label Oct 2, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
relnotes Marks issues that should be documented in the release notes of the next release.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants