Mac OS X version 10.5 or later is required for zerocost-exceptions???
-
This strange error message has appeared before the closing brace of a
synchronized statement when I switched the deployment target to Tiger in
my project settings.
The block may be empty, the error won't go. I have a similar synchronized
block elsewhere in another method but XCode does not complain about that
one. So what's wrong?
Jurgen -
On Feb 7, 2008 3:57 PM, Jurgen Vermeiren
<jurgen.vermeiren...> wrote:> The block may be empty, the error won't go. I have a similar synchronized
> block elsewhere in another method but XCode does not complain about that
> one. So what's wrong?
This is a very hard question to answer without the error message and
the relevant code...
--Kyle Sluder -
On Feb 7, 2008, at 12:57 PM, Jurgen Vermeiren wrote:> This strange error message has appeared before the closing brace of a
> synchronized statement when I switched the deployment target to
> Tiger in
> my project settings.
>
> The block may be empty, the error won't go. I have a similar
> synchronized
> block elsewhere in another method but XCode does not complain about
> that
> one. So what's wrong?
To answer the question in your subject line, yes -- 10.5 or later is
required to take advantage of "zero cost" Objective-C exceptions.
They are also a 64 bit only issue.
As some other responder said, to answer the question posed above will
require some code or more context.
b.bum -
It's good to know that it's a 64 bit only issue. The error does disappear
if I set i386 instead. I must say that having my x86_64 build working only
in Leopard is not too much of a problem for me. It's rather intriguing
because the code does nothing extraordinary, as you can judge by yourself:
- (void) logMsg :(NSString*)msg critical:(Boolean)critical
{
NSDictionary* attr;
if( critical )
attr = [NSDictionary dictionaryWithObject :[NSColor redColor]
forKey:NSForegroundColorAttributeName];
else
attr = [NSDictionary dictionaryWithObject :[NSColor blackColor]
forKey:NSForegroundColorAttributeName];
@synchronized(self)
{
NSTextStorage* text = [logView textStorage];
unsigned len = [[text string] length];
unsigned msglen = [msg length];
[text replaceCharactersInRange :NSMakeRange( len, 0 ) withString:msg];
[text setAttributes :attr range:NSMakeRange( len, msglen )];
[logView scrollRangeToVisible :NSMakeRange( len + msglen, 0 )];
}
}> On Feb 7, 2008, at 12:57 PM, Jurgen Vermeiren wrote:
>> This strange error message has appeared before the closing brace of a
>> synchronized statement when I switched the deployment target to
>> Tiger in
>> my project settings.
>>
>> The block may be empty, the error won't go. I have a similar
>> synchronized
>> block elsewhere in another method but XCode does not complain about
>> that
>> one. So what's wrong?
>
> To answer the question in your subject line, yes -- 10.5 or later is
> required to take advantage of "zero cost" Objective-C exceptions.
> They are also a 64 bit only issue.
>
> As some other responder said, to answer the question posed above will
> require some code or more context.
>
> b.bum
>
> -
On Feb 7, 2008 AD, at 3:13 PM, Jurgen Vermeiren wrote:> It's good to know that it's a 64 bit only issue. The error does
> disappear
> if I set i386 instead. I must say that having my x86_64 build
> working only
> in Leopard is not too much of a problem for me. It's rather intriguing
> because the code does nothing extraordinary, as you can judge by
> yourself:
Check your deployment target... If you're building for ppc64 or x86_64
and your deployment target is anything less than 10.5, then you'll get
lots of runtime warnings & possibly some errors as well. You need to
target at least 10.5 for 64-bit builds, unless you're just using plain
C/C++ and the standard libraries.
Nick Zitzmann
<http://www.chronosnet.com/>


