]> git.lizzy.rs Git - rust.git/commitdiff
auto merge of #18386 : nikomatsakis/rust/issue-18208, r=pnkfelix
authorbors <bors@rust-lang.org>
Tue, 28 Oct 2014 12:26:50 +0000 (12:26 +0000)
committerbors <bors@rust-lang.org>
Tue, 28 Oct 2014 12:26:50 +0000 (12:26 +0000)
Avoid O(n^2) performance by reconsidering the full set of obligations only when we are about to report an error (#18208). I found it is still important to consider the full set in order to make tests like `let x: Vec<_> = obligations.iter().collect()` work.

I think we lack the infrastructure to write a regression test for this, but when I did manual testing I found a massive reduction in type-checking time for extreme examples like those found in #18208 vs stage0.

f? @dotdash


Trivial merge