Since I am using the substring and not including “.SubstringNotRequired”, I can 
just remove the “guard” block, tack on a “!” to substring’s identifier, and be 
done with it, right?

— 
Daryle Walker
Mac, Internet, and Video Game Junkie
darylew AT mac DOT com 

> On May 29, 2016, at 12:08 AM, Ken Thomases <k...@codeweavers.com> wrote:
> 
> On May 28, 2016, at 8:27 PM, Daryle Walker <dary...@mac.com> wrote:
>> 
>> The last argument to the method is a closure with four parameters. The first 
>> argument is an optional String. I can't think of a circumstance where it'll 
>> be NIL. (I need to know for testing.) Especially since it can be recreated 
>> in terms of the callback's second argument, which isn't optional. (So the 
>> string can be empty at worst.). Am I missing something, or is this a bug 
>> (and should be non-optional)?
> 
> One can pass NSStringEnumerationOptions.SubstringNotRequired in the options 
> to tell the framework to not bother creating that substring, which can be 
> expensive, if you don't need it.  In that case, it will pass nil to your 
> block.

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to