Boost logo

Boost :

From: Emil Dotchevski (emildotchevski_at_[hidden])
Date: 2006-08-09 14:23:47

Pavel Vozenilek wrote:

> The explicit support for a "exception transformer"
> inside boost::exception is not needed (visiting
> all stored data is a different thing).
> So my arguing is OT in this regard.

Yes, we were discussing how and if enumerating info stored in
boost::exception should be supported.

I think that instead of enumerating info, we need two other functions:

1. The ability to copy the contained info in one boost::exception to another
boost::exception, for folks like you who want to translate exceptions. I
could support the following syntax:

class my_exception: public boost::exception { };
class translated_exception: public boost::exception { };

catch( my_exception & x )
    throw translated_exception() << x;

2. The ability to dump all info stored in boost::exception objects, for
debugging purposes. Something like:

boost::exception & x;

std::string info( x.what() ); //get a string of all info stored in

Is this alright? Does anyone still think that it is necessary to support
enumeration of the info contained in boost::exception?


P.S. The full documentation for Boost Exception is here:

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