Re: NSLog and [NSDictionary description], bug?
Re: NSLog and [NSDictionary description], bug?
- Subject: Re: NSLog and [NSDictionary description], bug?
- From: Allan Odgaard <email@hidden>
- Date: Tue, 6 Apr 2004 13:51:59 +0200
On 6. Apr 2004, at 13:21, Nicko van Someren wrote:
The correct and safe way to do what you want to do is
NSLog(@"%@",myDictionary), which also takes less typing!
Just to be pedantic, if you want the *description* of the dictionary,
as returned by the description method, you have to explicitly provide
[myDictionary description] (i.e. not less typing), since NSLog will use
CFCreateStringWithFormatAndArguments, which treat the %@ placeholder as
being a CoreFoundation object, which description is often more verbose
(at least with dictionaries, dates and arrays IIRC).
** Cocoa FAQ: <
http://www.alastairs-place.net/cocoa/faq.txt> **
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.