exception under g++

Kraus Philipp philipp.kraus@flashpixx.de
Sat Jul 16 17:57:00 GMT 2011


Hi Dima,

thanks for your answer.

Am 16.07.2011 um 15:02 schrieb Dima Pasechnik:

> you ought to post steps to reproduce the problem, if there is one.
> By the way, can you check that you link against libgcc using -shared-libgcc?
> 
> You can also try to figure out whether is this not a purely g++ problem, by
> installing g++ 4.3.4 on Linux, say, and trying your code with it.

I can locate the problem in the code, that the problem is only produced in this class, in which C and C++ code is mixed.
I use a call of the libxml2, which is a C library. The code works under Linux and OSX. 

> Windows has a number of ways to handle exceptions, e.g. MSVC++
> exceptions used to be (or maybe are, still) not conforming to C++
> standard.

I use for my project only Cygwins g++ / gcc, not MinGW or MSVC, so do you know any things about this? On some websites
there are the -fexceptions flag is seen, but if I set them, the problem isn't be solved. 

I have try to catch my thrown exception with catch (...), catch (myexception e) or some other catches, but the exception is not
be caught. Should I recompile all my libraries with the -fexceptions flag or only my code? Are there other flags for correct 
exception handling under the Cygwin gcc / g++?

Thanks

Phil

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple



More information about the Cygwin mailing list