Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

PrevUpHomeNext

Type from

boost::contract::from — Indicate the kind of operation where the contract assertion failed.

Synopsis

// In header: <boost/contract/core/exception.hpp>



enum from { from_constructor, from_destructor, from_function };

Description

This is passed as a parameter to the assertion failure handler functions. For example, it might be necessary to know in which operation an assertion failed to make sure exceptions are never thrown from destructors, not even when contract failure handlers are programmed by users to throw exceptions instead of terminating the program.

See Also:

Throw on Failure

from_constructor
Assertion failed when checking contracts for constructors.
from_destructor
Assertion failed when checking contracts for destructors .
from_function
Assertion failed when checking contracts for functions (members or not, public or not).

PrevUpHomeNext