Boost logo

Boost :

From: Carl Daniel (cpdaniel_at_[hidden])
Date: 2003-09-21 09:01:40


carlos pizano wrote:

> That helps. So if you where to "throw" inside a translator, what
> happens after that is not what you would think it should happen, that
> is, proper stack unwinding at each nested level, but something more
> along the lines
> of random behavior.
>
> I wonder why VC does generate just a warning (level 4) about this and
> not an error...

Under the next release of VC ("Whidbey"), VC will no longer catch SE's with
catch(...) when compiled with /EHs.

>
> Reading David Abrahams' Guidelines at
> http://www.boost.org/more/error_handling.html
>
> Seems that a better execution_monitor will nicely complement them.
> That
> is, if you subscribe to the camp that wants to avoid catch(...)
> whenever possible then one should only catch specific kinds of
> exceptions and
> whenever possible let execution_monitor handle the rest.
>

I do subscribe to that camp: catch(...) should be used only in very special
scircumstances. Otherwise, catch what you can handle (and expect) and let
everything else go by.

-cd


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk