[swift-evolution] Take 2: Stdlib closure argument labels and parameter names

Anton Zhilin antonyzhilin at gmail.com
Wed Jun 29 04:54:33 CDT 2016


Dave Abrahams via swift-evolution <swift-evolution at ...> writes:

> I've updated my pull request with a much more conservative set of
> changes that preserves/restores label-free-ness for all “term of art”
> functional methods such as filter and reduce.
> 
> https://github.com/apple/swift/pull/2981
> 
> My current thoughts are that many of the `by:` labels are awkward and
> not adding much.  Perhaps they all ought to be omitted.

In sort, by: makes perfect sense.
In lexicographicallyPrecedes (elementsEqual), by: makes some sense, 
because Precedes (Equal) is in method name.

starts(with:by:) looks odd, maybe starts(with:comparingBy:) ?


More information about the swift-evolution mailing list