Mmh, I think like the do while -> repeat while change it makes sense, but not 
enough to displace the obvious meaning of the original... but then again, I 
lost back then...

Sent from my iPhone

Begin forwarded message:

> From: Andrew Trick via swift-evolution <swift-evolution@swift.org>
> Date: 18 July 2017 at 21:33:31 BST
> To: Taylor Swift <kelvin1...@gmail.com>
> Cc: swift-evolution <swift-evolution@swift.org>
> Subject: Re: [swift-evolution] Pitch: Improved Swift pointers
> Reply-To: Andrew Trick <atr...@apple.com>
> 
> 
>>> On Jul 18, 2017, at 11:36 AM, Taylor Swift <kelvin1...@gmail.com> wrote:
>>> 
>>> > fix the ordering of the arguments in 
>>> > initializeMemory<Element>(as:at:count:to:)
>>> 
>>> I think this ordering was an attempt to avoid confusion with binding
>>> memory where `to` refers to a type. However, it should be consistent
>>> with `UnsafePointer.initialize`, so we need to pick one of those to
>>> change.
>> 
>> This would be a non-issue had we just been consistent with the rest of the 
>> stdlib and named this argument `repeating:` instead of `to:`. But 
>> `ptr.initialize(repeating: 255, count: 100)` doesn’t read quite as naturally 
>> in English as `ptr.initialize(to: 255, count: 100)` which is why I left this 
>> idea out of the proposal. Now that you mention the problem with 
>> `initializeMemory<Element>(as:at:count:to:)`, it might be a good idea to add 
>> this rename back into it.
> 
> I think `repeating` is much more clear.
> 
> -Andy
> _______________________________________________
> swift-evolution mailing list
> swift-evolution@swift.org
> https://lists.swift.org/mailman/listinfo/swift-evolution
_______________________________________________
swift-evolution mailing list
swift-evolution@swift.org
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to