Updates for MacOS-X compatibility

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@26690 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
rfm 2008-06-23 07:15:10 +00:00
parent 0f579d5620
commit 18944ced01
5 changed files with 34 additions and 15 deletions

View file

@ -2,6 +2,12 @@
#include "Foundation/Foundation.h"
static void
handler(NSException *e)
{
NSLog(@"Caught %@", e);
}
int main()
{
CREATE_AUTORELEASE_POOL(arp);
@ -43,6 +49,9 @@ int main()
printf("Second task has completed\n");
NSSetUncaughtExceptionHandler(handler);
[NSException raise: NSGenericException format: @"an exception"];
DESTROY(arp);
return 0;
}