[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: G++ Exceptions



> 
> Is there a version of g++ anywhere that has a full implementation of
> exception handling? The one in the GCC 2.7.2-1.2 won't catch a derived
> exception with the handler for its base class, and won't catch unexpected
> exceptions with "catch ( ... )".

When I still tried to use exceptions, I think in the simple
cases the things you describe (at least derived exceptions)
went OK if the programme was compiled with:
  -O0 -fhandle-exceptions -frtti
(Yes, no optimisation). Before I got all those options, I used to
have a lot of trouble, and by te time I did get the options right
I just gave up on exceptions.

I still think I've got an example of a c++ file that gcc doesn't compile
correctly with the above options, but I'm not sure. When I bugged the
gcc team about this, the reply I got was that 2.7.2 is supposed to
handle derived exceptions (and I think the cach (...) ) correctly.

-- 
joost witteveen
            joost@rulcmc.leidenuniv.nl
          joostje@debian.org
--
Use Debian/GNU Linux!


--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
debian-devel-REQUEST@lists.debian.org . Trouble? e-mail to Bruce@Pixar.com


Reply to: