Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2004-03-10 07:56:57


Gennaro Prota wrote:
> On Tue, 09 Mar 2004 12:51:03 -0500, David Abrahams
> <dave_at_[hidden]> wrote:
>
>> Gennaro Prota <gennaro_prota_at_[hidden]> writes:
>>>
>>> Out of curiosity, you say "sad" because there have been previous
>>> discussions with Peter and he had a different opinion?
>>
>> No, because it means we have to concede an otherwise benign standard
>> language feature is rendered bad/dangerous/useless by various
>> operating environments:
>>
>> try
>> {
>> ...
>> }
>> catch(...)
>> {
>> //...
>> throw;
>> }
>>
>
> Well, yes, but it seemed that Peter was making a more general point
> ("any catch that can be replaced", not just catch(...))

Right, my point was that a catch+rethrow causes stack unwinding even if
there is ultimately no matching handler. This may or may not be the right
behavior for the particular context/platform, but in a low-level library, we
don't know, so we must be as transparent as possible.


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