Boost logo

Boost :

From: Greg Colvin (gcolvin_at_[hidden])
Date: 2001-03-20 01:40:10

From: Kevlin Henney <kevlin_at_[hidden]>
> In message <02dc01c0b0ff$0a6bf450$37781990_at_[hidden]>, Greg Colvin
> <gcolvin_at_[hidden]> writes
> >Let me suggest the following idiom as a reasonable way to report
> >fatal runtime errors:
> >
> > template <typename X>
> > void error(const X& x) throw() {
> > throw x;
> > }
> >
> >Yes, it looks silly. But it will force a call to unexpected(),
> >which by default will terminate(), and the client can replace
> >the default behavior via the standard set_unexpected() facility.
> As indeed a straight call to std::unexpected will do. What am I missing?

A way to communicate what the error is to the unexpected_handler?

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