On Jan 28, 2010, at 4:29 PM, Keith Blount wrote:

>                       [cleanedString appendFormat:@"%C", character];

If you're worried about efficiency, format conversions like this are 
particularly slow; so is building up an NSString a character at a time. It's 
more efficient to allocate a unichar[] buffer with sufficient capacity, put 
characters in it, and then create an NSString in one operation.

It's probably not a big deal, though, unless you're running this on extremely 
long strings or on huge numbers of them.

—Jens_______________________________________________

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

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

Reply via email to