[PATCH][Bug c++/12054] Fix C++ EH bug
Jason Merrill
jason@redhat.com
Wed Aug 27 18:53:00 GMT 2003
Thanks, but this is not a bug.
15.5.1 The terminate() function [except.terminate]
1 In the following situations exception handling must be abandoned for
less subtle error handling techniques:
- when the exception handling mechanism, after completing evaluation
of the expression to be thrown but
before the exception is caught (15.1), calls a user function that
exits via an uncaught exception,134)
- when the exception handling mechanism cannot find a handler for a
thrown exception (15.3), or
- when the destruction of an object during stack unwinding (15.2)
exits using an exception, or
__________________
134) For example, if the object being thrown is of a class with a
copy constructor, terminate() will be called if that copy construc-
tor exits with an exception during a throw.
Indeed, the cited section of the ABI document says
(If the copy constructor itself exits by throwing an exception,
terminate() is called.)
Jason
More information about the Gcc-patches
mailing list