Re: NSAssert and Unused Variable
Re: NSAssert and Unused Variable
- Subject: Re: NSAssert and Unused Variable
- From: Richard Somers <email@hidden>
- Date: Thu, 3 Apr 2008 13:42:01 -0600
On Apr 2, 2008, at 7:34PM, Chris Suter wrote:
int var __attribute__((__unused__));
Or use the following short cut found in cdefs.h.
#define __unused __attribute__((__unused__))
Which would make my example look like this which seems to work well.
int __unused error = foo();
NSAssert(error == 0, @"We have an assertion failure!");
Thanks to everyone for their comments. I learned something.
Regards, Richard
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden