using gcj for a different language - is it possible?

Andrew Pinski pinskia@physics.uc.edu
Sat Jan 10 05:30:00 GMT 2004


On Jan 9, 2004, at 21:25, Florin wrote:

> Do you happen to know if exception handling in Objective-C is anything 
> like
> the one in Smalltalk? Tom pointed this area out as potentially very
> difficult, since gcc might not support Smalltalk exception semantics 
> (in
> Smalltalk the handler is reached before any unwinding happens, and the
> handler gets to decide if the unwinding happens or not, it may choose 
> to
> retry the exception-generating operation).

There is no exception handling in Objective-C right now, well that is 
not true as
Objective-C (Apple flavor) does support exception handling but it is 
just using
setjmp/longjmp under neath unlike what the rest of GCC's exception 
handling (well
not quite true as GCC does support setjmp/longjmp exceptions for all 
targets).  The
rest of GCC (and except maybe Ada also) do unwinding using dwarf-2 
exceptions.

There is some discussions about if Objective-C should add exception 
handling (it might
be different than what Apple decided on, it might be more like 
SmallTalk but who
knows).

Since Objective-C is one of the languages where no one really has any 
control,
people are adding extensions on top the original definition.  Some of 
them are being
added to GCC but only for the NeXT's (Apple's) runtime.  I hope to get 
this changed so
that every language feature has to be supported by both runtimes, the 
GNU runtime and
Apple's.  (but this really does not matter to you but I wanted this out 
and in the
open).


> And does Objective-C support operations like #become: (switching the
> identities of two objects)?

If you mean something like -PoseAs: which changes class types at 
runtime, yes.
If that is not what you mean then can you help out here and explain 
what really
#become does?

Thanks,
Andrew Pinski



More information about the Java mailing list