Boost logo

Boost :

From: Alexander Terekhov (terekhov_at_[hidden])
Date: 2003-10-02 03:54:43

Alan.Griffiths_at_[hidden] wrote:
> While C++ exceptions might reasonably be presented as a specialisation of
> SEH exceptions the converse isn't true. (Aside from the unresolved question
> over sequence points SEH exceptions can occur without a throw expression,

I can write a pointer that would use something like IsBad*Ptr in its
"checking policy" and raise "access violation" via normal C++ throw-
expression. The same goes for underflows/overflows/whatnot. It does
NOT make any difference if "hardware" does it for you. Live with it.

SEH would become truly asynchronous if it could violate sequence
points. The only useful application of asynchronous exceptions is
asynchronous thread cancelation. You can do it inside async-cancel-
safe regions. But you're quite limited in what you can do in such

> the program is broken.

Not necessarily. In any event, you "might want" to do the takeover.
Now, if you try to unwind AND the program is really broken you may
never terminate and cause the takeover. If you insist on emergency
cleanup (it's always better to do it from the isolated environment,
but okay...) then the right way to do it is to use thread-specific
std::unexpected() handlers and/or "global" std::terminate() stuff.


Boost list run by bdawes at, gregod at, cpdaniel at, john at