Commits

Chris Lattner committed c652c62f887
When sorting through a list of candidates in a call overload set, introduce the notion of a "near miss" for an argument type mismatch. This allows us to prune the candidate set down in some cases. For example, in the testcase in rdar://22243469 we are able to go from: t.swift:6:3: error: cannot invoke 'process' with an argument list of type '(() throws -> ())' process { ^ t.swift:6:3: note: overloads for 'process' exist with these partially matching parameter lists: (UInt, fn: () -> Void), (UInt) down to: t.swift:6:3: note: expected an argument list of type '(UInt, () -> Void)' This paves the way for producing a better error in cases like this, but there are other bits of weirdness that need to be untangled first.