[iOS] Now use autorelease block. Code will compile with LLVM 3.0, xCode version >= 4.2.

This commit is contained in:
Kirill Zhdanovich 2013-06-03 16:30:02 +03:00 committed by Alex Zolotarev
parent 5a36fd2b77
commit f351682a71

View file

@ -31,14 +31,14 @@ int main(int argc, char * argv[])
LOG(LINFO, ("MapsWithMe started, detected CPU cores:", GetPlatform().CpuCores()));
NSSetUncaughtExceptionHandler(&exceptionHandler);
int retVal;
@autoreleasepool
{
Dummy * dummy = [[Dummy alloc] autorelease];
NSThread * thread = [[[NSThread alloc] initWithTarget:dummy selector:@selector(dummyThread:) object:nil] autorelease];
[thread start];
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
Dummy * dummy = [[Dummy alloc] autorelease];
NSThread * thread = [[[NSThread alloc] initWithTarget:dummy selector:@selector(dummyThread:) object:nil] autorelease];
[thread start];
int retVal = UIApplicationMain(argc, argv, nil, nil);
[pool release];
retVal = UIApplicationMain(argc, argv, nil, nil);
}
return retVal;
}