On Jan 9, 2009, at 8:11 AM, Graham Cox wrote:

On 10 Jan 2009, at 1:07 am, Steve Cronin wrote:

Under some circumstances I'm not sure how big a mutable object might need be.
So is there any guidance on coming up with a value for capacity?

[...]

It feels a little like premature optimization, but I do have to provide a value in the code....
Thanks for any feedback!
Steve

This came up a while back and the consensus was: don't bother at all. Just use [NSMutableArray array];

And the reason many people don't realize they can do this is that they overlook the superclass methods when considering a subclass. A lot of people don't even know that they can send +array to NSMutableArray!

Cheers,
Ken

_______________________________________________

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