On Feb 8, 2011, at 15:07, Fritz Anderson wrote:

> The documentation for AVAudioPlayer's initWithContentsOfURL:error: and 
> initWithData:error: methods, however, call for "the address of a 
> nil-initialized NSError object," whatever that is. I think they mean a 
> nil-initialized pointer to an NSError pointer. There's similar language for 
> AVAudioRecorder.
> 
> I can't imagine this is correct. It is against the semantics for NSError** 
> returns everywhere else in Cocoa. What would the method do with the nil, or 
> with a non-nil value, for that matter? I'd always assumed that the only thing 
> that happens to the input value of *error is that it is blindly overwritten.

You're right -- it's very strange, and the language as it stands is 
nonsensical, regardless of what the API intends to be passed.


_______________________________________________

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