Re: Weird build error
Re: Weird build error
- Subject: Re: Weird build error
- From: Michael Vannorsdel <email@hidden>
- Date: Thu, 17 Apr 2008 17:15:56 -0600
Change it to:
- (void)TestFunction
{
switch (1) {
case 1:
{
NSMutableArray *myArray=[[NSMutableArray alloc] init];
break;
}
}
}
No need to declare default if it's unused. Also you need to bracket
the statement in the switch if you're going to declare vars there.
On Apr 17, 2008, at 4:47 PM, Don Arnel wrote:
- (void)TestFunction
{
switch (1) {
case 1:
//NSMutableArray *myArray=[[NSMutableArray alloc] init];
break;
default:
}
(x)(error: label at end of compound statement)
}
_______________________________________________
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