On Dec 12, 2010, at 9:12 PM, Kyle Sluder wrote:

> On Sun, Dec 12, 2010 at 2:41 PM, WT <jrca...@gmail.com> wrote:
>> Hello,
>> 
>> according to the iOS 4.2 NSDateFormatter class documentation, the -init 
>> method is available in iOS 2.0 through iOS 3.2, but it does not offer an 
>> alternative method to initialize a newly allocated date formatter (or, if it 
>> does, I missed it on repeated readings of the docs). How then?
>> 
>> I went ahead and tried -init anyway and, sure enough, a problem arises:
> 
> Calling -[NSDateFormatter init] compiles fine for me, without
> warnings. Googling seems to indicate this is a docs bug; they removed
> -init from NSDateFormatter.h (actually commented it out) in 10.6/iOS 4
> and the documentation team's tools picked it up as a removal rather
> than just cleaning up the redundant declaration of -init.
> 
> Your stack trace points at a different problem. What does
> -[AppDelegate localPtBr] look like?

Ahh... thanks for both answers. I'll investigate further why I'm getting that 
malloc error after I get some sleep. Anyhow, here's

- (NSLocale*) localePtBr;
{
   if (localePtBr_ == nil)
   {
       localePtBr_ = [[NSLocale alloc] initWithLocaleIdentifier: @"pt_BR"];
   }

   return localePtBr_;
}

Thanks again.
WT_______________________________________________

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