diff --git a/doc/boost-exception.html b/doc/boost-exception.html index 72355a5..cb3f045 100644 --- a/doc/boost-exception.html +++ b/doc/boost-exception.html @@ -33,8 +33,8 @@
Class boost::exception is designed to be used as a universal base for user-defined exception types.
-An object of any type deriving from boost::exception can store data of arbitrary types, using the error_info wrapper and operator<<.
+An object of any type deriving from boost::exception can store data of arbitrary types, using the error_info wrapper and operator<<.
To retrieve data from a boost::exception object, use the get_error_info function template.
T must have accessible copy constructor and must not be a reference (there is no requirement that T's copy constructor does not throw.)
This class template is used to associate a Tag type with a value type T. Objects of type error_info<Tag,T> can be passed to operator<< to be stored in objects of type boost::exception.
+This class template is used to associate a Tag type with a value type T. Objects of type error_info<Tag,T> can be passed to operator<< to be stored in objects of type boost::exception.
The header <boost/exception/error_info.hpp> provides a declaration of the error_info template, which is sufficient for the purpose of typedefing an instance for specific Tag and T, like this:
#include <boost/exception/error_info.hpp> typedef boost::error_info<struct tag_errno,int> errno_info;-
Of course, to actually add an error_info object to exceptions using operator<<, or to retrieve it using get_error_info, you must first #include <boost/exception/info.hpp>.
-Of course, to actually add an error_info object to exceptions using operator<<, or to retrieve it using get_error_info, you must first #include <boost/exception/info.hpp>.
+#include <boost/exception/info.hpp>
namespace boost { template <class E, class Tag, class T> - E const & operator<<( E const & x, error_info<Tag,T> const & v ); + E const & operator<<( E const & x, error_info<Tag,T> const & v ); }
E must be boost::exception, or a type that derives (indirectly) from boost::exception.
@@ -224,14 +223,14 @@ boostx.
std::bad_alloc, or any exception emitted by the T copy constructor.
-#include <boost/exception/info_tuple.hpp>
namespace
boost
{
template <class E, class Tag1, class T1, ..., class TagN, class TN>
- E const & operator<<( E const & x,
+ E const & operator<<( E const & x,
tuple<
error_info<Tag1,T1>,
...,
@@ -261,12 +260,12 @@ boost
Nothing.
The interface of get_error_info may be affected by the build Configuration.
+The interface of get_error_info may be affected by the build configuration macros.
#include <boost/exception/enable_error_info.hpp>
@@ -403,7 +402,7 @@ boost std::string diagnostic_information( boost::exception const & x ); }This function iterates over all data objects stored in the boost::exception through operator<<. The returned string is constructed by converting each data object to string and then concatenating these strings together.
+This function iterates over all data objects stored in the boost::exception through operator<<. The returned string is constructed by converting each data object to string and then concatenating these strings together.
When the error_info<Tag,T> template is instantiated, the system attempts overload resolution for an unqualified call to to_string(x), where x is of type T. If this is successful, the to_string overload is expected to return std::string and is used to convert objects of type T to string.
Otherwise, the system attempts overload resolution for s << x, where s is a std::ostringstream and x is of type T. If this is successful, the operator<< overload is used to convert objects of type T to string.
Otherwise the system is unable to convert objects of type T to string, and an unspecified stub string value is used without issuing a compile error.
diff --git a/doc/Configuration.html b/doc/configuration_macros.html similarity index 84% rename from doc/Configuration.html rename to doc/configuration_macros.html index 096904c..d6d11fd 100644 --- a/doc/Configuration.html +++ b/doc/configuration_macros.html @@ -3,7 +3,7 @@ -Boost Exception responds to the following configuration macros:
-BOOST_NO_RTTI/BOOST_NO_TYPEID
-The first macro prevents Boost Exception from using dynamic_cast and dynamic typeid. If the second macro is also defined, Boost Exception does not use static typeid either. Defining either macro does not have an observable degrading effect on the library functionality, except for the following:
+BOOST_NO_RTTI
BOOST_NO_TYPEID
The first macro prevents Boost Exception from using dynamic_cast and dynamic typeid. If the second macro is also defined, Boost Exception does not use static typeid either. There are no observable degrading effects on the library functionality, except for the following:
-By default, the get_error_info function template can be called with any exception type. If BOOST_NO_RTTI is defined, get_error_info can be used only with objects of type boost::exception.
Note: the configuration where BOOST_NO_RTTI is defined but BOOST_NO_TYPEID is not defined is specific for MSVC compilers; it reduces RTTI overhead without fully disabling std::type_info. For most (all?) other compilers, to use Boost Exception without RTTI, both BOOST_NO_RTTI and BOOST_NO_TYPEID must be defined.
BOOST_EXCEPTION_DISABLE
By default, enable_current_exception and enable_error_info are integrated directly in the throw_exception function. Defining BOOST_EXCEPTION_DISABLE disables this integration.
Note that on some non-conformant compilers, for example MSVC 7.0 and older, as well as BCC, BOOST_EXCEPTION_DISABLE is implicitly defined in boost/throw_exception.hpp.
diff --git a/doc/diagnostic_information.html b/doc/diagnostic_information.html index d775718..fdd7d76 100644 --- a/doc/diagnostic_information.html +++ b/doc/diagnostic_information.html @@ -28,7 +28,7 @@ boost std::string diagnostic_information( boost::exception const & x ); }This function iterates over all data objects stored in the boost::exception through operator<<. The returned string is constructed by converting each data object to string and then concatenating these strings together.
+This function iterates over all data objects stored in the boost::exception through operator<<. The returned string is constructed by converting each data object to string and then concatenating these strings together.
When the error_info<Tag,T> template is instantiated, the system attempts overload resolution for an unqualified call to to_string(x), where x is of type T. If this is successful, the to_string overload is expected to return std::string and is used to convert objects of type T to string.
Otherwise, the system attempts overload resolution for s << x, where s is a std::ostringstream and x is of type T. If this is successful, the operator<< overload is used to convert objects of type T to string.
Otherwise the system is unable to convert objects of type T to string, and an unspecified stub string value is used without issuing a compile error.
diff --git a/doc/enable_current_exception.html b/doc/enable_current_exception.html index 328365c..b481f01 100644 --- a/doc/enable_current_exception.html +++ b/doc/enable_current_exception.html @@ -49,7 +49,7 @@ throw boost::enabT must have accessible copy constructor and must not be a reference (there is no requirement that T's copy constructor does not throw.)
This class template is used to associate a Tag type with a value type T. Objects of type error_info<Tag,T> can be passed to operator<< to be stored in objects of type boost::exception.
+This class template is used to associate a Tag type with a value type T. Objects of type error_info<Tag,T> can be passed to operator<< to be stored in objects of type boost::exception.
The header <boost/exception/error_info.hpp> provides a declaration of the error_info template, which is sufficient for the purpose of typedefing an instance for specific Tag and T, like this:
#include <boost/exception/error_info.hpp> typedef boost::error_info<struct tag_errno,int> errno_info;-
Of course, to actually add an error_info object to exceptions using operator<<, or to retrieve it using get_error_info, you must first #include <boost/exception/info.hpp>.
+Of course, to actually add an error_info object to exceptions using operator<<, or to retrieve it using get_error_info, you must first #include <boost/exception/info.hpp>.
Class boost::exception is designed to be used as a universal base for user-defined exception types.
-An object of any type deriving from boost::exception can store data of arbitrary types, using the error_info wrapper and operator<<.
+An object of any type deriving from boost::exception can store data of arbitrary types, using the error_info wrapper and operator<<.
To retrieve data from a boost::exception object, use the get_error_info function template.
Nothing.
diff --git a/doc/exception_diagnostic_information_hpp.html b/doc/exception_diagnostic_information_hpp.html index 2fe73ba..8214df6 100644 --- a/doc/exception_diagnostic_information_hpp.html +++ b/doc/exception_diagnostic_information_hpp.html @@ -22,14 +22,13 @@#include <exception> -#include <string> +#include <string> namespace boost { - class exception; - std::string diagnostic_information( boost::exception const & x ); + class exception; + std::string diagnostic_information( boost::exception const & x ); }
#include <boost/exception/info.hpp>
namespace boost { template <class E, class Tag, class T> - E const & operator<<( E const & x, error_info<Tag,T> const & v ); + E const & operator<<( E const & x, error_info<Tag,T> const & v ); }
E must be boost::exception, or a type that derives (indirectly) from boost::exception.
diff --git a/doc/get_error_info.html b/doc/get_error_info.html index 34b511e..224f2d6 100644 --- a/doc/get_error_info.html +++ b/doc/get_error_info.html @@ -35,18 +35,18 @@ boostNothing.
The interface of get_error_info may be affected by the build Configuration.
+The interface of get_error_info may be affected by the build configuration macros.
Integrating Boost Exception in Existing Exception Class Hierarchies
-Transporting of Exceptions Between Threads
#include <boost/exception/info_tuple.hpp>
namespace
boost
{
template <class E, class Tag1, class T1, ..., class TagN, class TN>
- E const & operator<<( E const & x,
+ E const & operator<<( E const & x,
tuple<
error_info<Tag1,T1>,
...,
diff --git a/doc/tutorial_diagnostic_information.html b/doc/tutorial_diagnostic_information.html
index 916f753..8a986eb 100644
--- a/doc/tutorial_diagnostic_information.html
+++ b/doc/tutorial_diagnostic_information.html
@@ -22,7 +22,7 @@
Diagnostic Information
Boost Exception provides a namespace-scope function diagnostic_information which takes a boost::exception. The returned string contains:
-- the string representation of all data objects added to the boost::exception through operator<<;
+- the string representation of all data objects added to the boost::exception through operator<<;
- the output from std::exception::what;
- additional platform-specific diagnostic information.
diff --git a/doc/tutorial_enable_error_info.html b/doc/tutorial_enable_error_info.html
index e0e8cd3..8dbb224 100644
--- a/doc/tutorial_enable_error_info.html
+++ b/doc/tutorial_enable_error_info.html
@@ -49,7 +49,7 @@ my_container
}
};
-The call to enable_error_info<T> gets us an object of unspecified type which is guaranteed to derive from both boost::exception and T. This makes it possible to use operator<< to store additional information in the exception object. The exception can be intercepted as T &, so existing exception handling will not break. It can also be intercepted as boost::exception &, so that more information can be added to the exception at a later time.
+The call to enable_error_info<T> gets us an object of unspecified type which is guaranteed to derive from both boost::exception and T. This makes it possible to use operator<< to store additional information in the exception object. The exception can be intercepted as T &, so existing exception handling will not break. It can also be intercepted as boost::exception &, so that more information can be added to the exception at a later time.
See Also:
Boost Exception
diff --git a/doc/tutorial_transporting_data.html b/doc/tutorial_transporting_data.html
index 57fe771..59b1189 100644
--- a/doc/tutorial_transporting_data.html
+++ b/doc/tutorial_transporting_data.html
@@ -41,7 +41,7 @@ f()
First, we instantiate the error_info template using a unique identifier -- tag_errno, and the type of the info it identifies -- int. This provides compile-time type safety for the various values stored in exception objects.
Second, we define class my_error, which derives from boost::exception.
-Finally, (3) illustrates how the typedef from (1) can be used with operator<< to store values in exception objects at the point of the throw.
+Finally, (3) illustrates how the typedef from (1) can be used with operator<< to store values in exception objects at the point of the throw.
The stored errno value can be recovered at a later time like this:
// ...continued