[swift-users] edit array

Nate Birkholz nbirkholz at gmail.com
Wed Apr 26 11:54:00 CDT 2017


Relatively straightforward to write this, which usually has meant "no" to adding something to the standard library. (Not that I agree with that measure.)

Sent from my iPhone, please excuse brevity and errors

> On Apr 26, 2017, at 11:13 AM, Ole Begemann via swift-users <swift-users at swift.org> wrote:
> 
> On 26.04.2017 17:01, J.E. Schotsman via swift-users wrote:
>>> On 26 Apr 2017, at 16:54, Rien <Rien at Balancingrock.nl> wrote:
>>> 
>>> Agree, though the function should probably be named something like: withEach instead of forEach.
>>> Maybe worth a proposal on evolution?
>> Let’s wait until the people at the other side of the big lake have had time to react.
> 
> There have been requests for something like this on swift-evolution, e.g. here in the context of the discussion about a `reduce` variant that takes `inout` arguments: https://lists.swift.org/pipermail/swift-evolution/Week-of-Mon-20170123/030641.html
> 
> An alternative might be to add a variant of `map` to `MutableCollection` that mutates the collection directly, see: https://lists.swift.org/pipermail/swift-evolution/Week-of-Mon-20170123/030643.html.
> 
> But as far as I know there hasn't been a proposal for adding this. (Is it important enough to have in the standard library? I don't know.)
> 
> _______________________________________________
> swift-users mailing list
> swift-users at swift.org
> https://lists.swift.org/mailman/listinfo/swift-users


More information about the swift-users mailing list