diff --git a/doc/BOOST_THROW_EXCEPTION.html b/doc/BOOST_THROW_EXCEPTION.html index 89395fb..7d8806f 100644 --- a/doc/BOOST_THROW_EXCEPTION.html +++ b/doc/BOOST_THROW_EXCEPTION.html @@ -27,15 +27,15 @@ #include <boost/current_function.hpp> #define BOOST_THROW_EXCEPTION(x)\ ::boost::throw_exception( ::boost::enable_error_info(x) <<\ - ::boost::throw_function(BOOST_CURRENT_FUNCTION) <<\ + ::boost::throw_function(BOOST_THROW_EXCEPTION_CURRENT_FUNCTION) <<\ ::boost::throw_file(__FILE__) <<\ ::boost::throw_line((int)__LINE__) ) #else #define BOOST_THROW_EXCEPTION(x) ::boost::throw_exception(x) #endif -

This macro takes an exception object, records BOOST_CURRENT_FUNCTION, __FILE__ and __LINE__ in it, and forwards it to throw_exception. To recover this information at the catch site, use get_error_info; the information is also included in the message returned by diagnostic_information.

+

This macro takes an exception object, records the current function name, __FILE__ and __LINE__ in it, and forwards it to throw_exception. To recover this information at the catch site, use get_error_info; the information is also included in the message returned by diagnostic_information.


-See also: Boost Exception | boost/throw_exception.hpp | Frequently Asked Questions +See also: Boost Exception | boost/throw_exception.hpp | Configuration Macros | Frequently Asked Questions
diff --git a/doc/boost_throw_exception_hpp.html b/doc/boost_throw_exception_hpp.html index 735ac77..a99cd9b 100644 --- a/doc/boost_throw_exception_hpp.html +++ b/doc/boost_throw_exception_hpp.html @@ -27,7 +27,7 @@ #include <boost/current_function.hpp> #define BOOST_THROW_EXCEPTION(x)\ ::boost::throw_exception( ::boost::enable_error_info(x) <<\ - ::boost::throw_function(BOOST_CURRENT_FUNCTION) <<\ + ::boost::throw_function(BOOST_THROW_EXCEPTION_CURRENT_FUNCTION) <<\ ::boost::throw_file(__FILE__) <<\ ::boost::throw_line((int)__LINE__) ) #else diff --git a/doc/throw_exception.html b/doc/throw_exception.html index 4c24cda..eb03fdb 100644 --- a/doc/throw_exception.html +++ b/doc/throw_exception.html @@ -32,14 +32,17 @@ boost void throw_exception( E const & e ); #endif } -

Requirements:

-

E must derive publicly from std::exception.

-

Effects:

-

Effects:

+
-

Note:

-

Under BOOST_NO_EXCEPTIONS, unless BOOST_EXCEPTION_DISABLE is also defined, users can examine the passed exception object using boost::get_error_info, or format an automatic diagnostic message using boost::diagnostic_information.

+

Requirements:

+

E must derive publicly from std::exception. E may or may not derive from boost::exception.

+

Notes:

+

See also: BOOST_THROW_EXCEPTION | Boost Exception | boost/throw_exception.hpp | Configuration Macros | enable_current_exception | Frequently Asked Questions | Transporting of Exceptions Between Threads
diff --git a/include/boost/throw_exception.hpp b/include/boost/throw_exception.hpp index c1bff43..7b5d4ed 100644 --- a/include/boost/throw_exception.hpp +++ b/include/boost/throw_exception.hpp @@ -41,8 +41,11 @@ #if !defined( BOOST_EXCEPTION_DISABLE ) # include +#if !defined(BOOST_THROW_EXCEPTION_CURRENT_FUNCTION) # include -# define BOOST_THROW_EXCEPTION(x) ::boost::exception_detail::throw_exception_(x,BOOST_CURRENT_FUNCTION,__FILE__,__LINE__) +# define BOOST_THROW_EXCEPTION_CURRENT_FUNCTION BOOST_CURRENT_FUNCTION +#endif +# define BOOST_THROW_EXCEPTION(x) ::boost::exception_detail::throw_exception_(x,BOOST_THROW_EXCEPTION_CURRENT_FUNCTION,__FILE__,__LINE__) #else # define BOOST_THROW_EXCEPTION(x) ::boost::throw_exception(x) #endif