Re: Can anyone confirm this IB Bug?
Re: Can anyone confirm this IB Bug?
- Subject: Re: Can anyone confirm this IB Bug?
- From: Jim Correia <email@hidden>
- Date: Sun, 10 Aug 2008 10:26:29 -0400
On Aug 4, 2008, at 1:15 PM, Kevin Cathey wrote:
To debug category replacement, set the environment variable
OBJC_PRINT_REPLACED_METHODS on your executable to any value. Then,
run your executable. You will get a list of all the category methods
that are being replaced with what, and you can see for sure if your
implementation of firstObject is smashing another in the Objective-C
runtime.
That said, for now, you will need to change the name of your method
(maybe cfFirstObject?). Please file a bug on Foundation so they can
add this common method to NSArray.
In addition to Kevin's advice, if I were writing a -firstObject method
on NSArray, I'd make it behave just like -lastObject for an empty array.
"The object in the array with the highest index value. If the array
is empty, returns nil."
Jim
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden