[swift-evolution] [Pitch] Make the first parameter in a function declaration follow the same rules as the others
Dave Abrahams
dabrahams at apple.com
Fri Mar 11 15:30:22 CST 2016
> On Mar 11, 2016, at 11:27 AM, Joe Groff <jgroff at apple.com> wrote:
>
>>
>> On Mar 11, 2016, at 11:20 AM, Jordan Rose via swift-evolution <swift-evolution at swift.org <mailto:swift-evolution at swift.org>> wrote:
>>
>>
>>> On Mar 10, 2016, at 15:34 , Dave Abrahams via swift-evolution <swift-evolution at swift.org <mailto:swift-evolution at swift.org>> wrote:
>>>
>>> on Wed Mar 09 2016, Jordan Rose <swift-evolution at swift.org <mailto:swift-evolution at swift.org>> wrote:
>>>
>>>> This is my concern too. Our guidelines often lead to the first
>>>> parameter having a label, but usually that name isn't the same as the
>>>> name of the parameter—one's a preposition, the other's a noun. I'm
>>>> pretty sure the common case is still unlabeled.
>>>
>>> It's about 50/50 (slight edge to labeled first parameters) in the
>>> imported Cocoa APIs.
>>
>> If it's easy to get these numbers, how many of the first parameters have the same label as the parameter name?
>
> If you're going to measure that, you should also measure it for second, third, ..., Nth parameters too for comparison.
Anyone who wants to measure is free to do so: simple regexps and wc generally work for this purpose.
https://github.com/apple/swift-3-api-guidelines-review/tree/swift-3/Platforms
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20160311/b4c27b27/attachment.html>
More information about the swift-evolution
mailing list