This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/14026] std::uncaught_exception is true although there are no uncaught exceptions (rethrow, ghost exception)
- From: "pcarlini at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 5 Feb 2004 21:53:09 -0000
- Subject: [Bug libstdc++/14026] std::uncaught_exception is true although there are no uncaught exceptions (rethrow, ghost exception)
- References: <20040205105427.14026.hubert.schmid@stud.uka.de>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From pcarlini at suse dot de 2004-02-05 21:53 -------
Yes, it's a libstdc++ bug.
It looks like uncaught_exception() has always (3.0.0 ->) been buggy in case of
rethrow: globals->uncaughtExceptions (which is an unsigned int) is not increased
from 0, then when is decreased in the catch block becomes (unsigned int)(-1) and
uncaught_exception, which is globals->uncaughtExceptions != 0, returns 1. Ouch!
--
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |pcarlini at suse dot de
|dot org |
Status|NEW |ASSIGNED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14026