To @try or not?
To @try or not?
- Subject: To @try or not?
- From: James Bucanek <email@hidden>
- Date: Fri, 8 Oct 2004 00:04:00 -0700
Greetings,
I'm a fairly new Cocoa/Obj-C programmer.
I was just about to start writing @synchronized and @try/@catch blocks when I read this in the documentation:
Note: Using either of these features in a program, renders the application
runnable only in Mac OS X v10.3 and later because runtime support for exception
handling and synchronization is not present in earlier versions of the software.
I have it in the back of my mind that the program I'm writing should run under 10.2 as well. So, here are my questions:
(1) Are there alternative exception handling and thread synchronization techniques or libraries that will work in 10.2 and later? I saw a reference in the gcc 3.3 release notes to NSException and NS_DURING/NS_HANDLER. Are these the standard pre 10.3 exception constructs? Are there any significant advantages to using @try over NS_DURING?
(2) If I start writing code using @try/@catch and @synchronized, how difficult will it be to retrofit that code so it will work in 10.2?
Thanks,
James
--
James Bucanek <
mailto:email@hidden>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden