Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r85636 - in branches/release: boost boost/exception/detail libs/exception/test
From: emil_at_[hidden]
Date: 2013-09-10 01:54:53


Author: emildotchevski
Date: 2013-09-10 01:54:53 EDT (Tue, 10 Sep 2013)
New Revision: 85636
URL: http://svn.boost.org/trac/boost/changeset/85636

Log:
Merging recent changes from trunk.

Text files modified:
   branches/release/boost/exception/detail/clone_current_exception.hpp | 11 ++++++++++-
   branches/release/boost/exception/detail/exception_ptr.hpp | 3 ++-
   branches/release/boost/throw_exception.hpp | 7 +++++--
   branches/release/libs/exception/test/cloning_test.cpp | 2 ++
   branches/release/libs/exception/test/throw_exception_test.cpp | 8 ++++----
   5 files changed, 23 insertions(+), 8 deletions(-)

Modified: branches/release/boost/exception/detail/clone_current_exception.hpp
==============================================================================
--- branches/release/boost/exception/detail/clone_current_exception.hpp Tue Sep 10 01:44:02 2013 (r85635)
+++ branches/release/boost/exception/detail/clone_current_exception.hpp 2013-09-10 01:54:53 EDT (Tue, 10 Sep 2013) (r85636)
@@ -1,10 +1,16 @@
-//Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc.
+//Copyright (c) 2006-2013 Emil Dotchevski and Reverge Studios, Inc.
 
 //Distributed under the Boost Software License, Version 1.0. (See accompanying
 //file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
 
 #ifndef UUID_81522C0EB56511DFAB613DB0DFD72085
 #define UUID_81522C0EB56511DFAB613DB0DFD72085
+#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
+#pragma GCC system_header
+#endif
+#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
+#pragma warning(push,1)
+#endif
 
 #ifdef BOOST_NO_EXCEPTIONS
 # error This header requires exception handling to be enabled.
@@ -44,4 +50,7 @@
         }
     }
 
+#if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
+#pragma warning(pop)
+#endif
 #endif

Modified: branches/release/boost/exception/detail/exception_ptr.hpp
==============================================================================
--- branches/release/boost/exception/detail/exception_ptr.hpp Tue Sep 10 01:44:02 2013 (r85635)
+++ branches/release/boost/exception/detail/exception_ptr.hpp 2013-09-10 01:54:53 EDT (Tue, 10 Sep 2013) (r85636)
@@ -21,6 +21,7 @@
 #include <boost/exception/diagnostic_information.hpp>
 #include <boost/exception/detail/type_info.hpp>
 #include <boost/exception/detail/clone_current_exception.hpp>
+#include <boost/units/detail/utility.hpp>
 #include <boost/shared_ptr.hpp>
 #include <stdexcept>
 #include <new>
@@ -89,7 +90,7 @@
     std::string
     to_string( original_exception_type const & x )
         {
- return x.value()->name();
+ return units::detail::demangle(x.value()->name());
         }
 #endif
 

Modified: branches/release/boost/throw_exception.hpp
==============================================================================
--- branches/release/boost/throw_exception.hpp Tue Sep 10 01:44:02 2013 (r85635)
+++ branches/release/boost/throw_exception.hpp 2013-09-10 01:54:53 EDT (Tue, 10 Sep 2013) (r85636)
@@ -1,6 +1,6 @@
 #ifndef UUID_AA15E74A856F11E08B8D93F24824019B
 #define UUID_AA15E74A856F11E08B8D93F24824019B
-#if defined(__GNUC__) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
+#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
 #pragma GCC system_header
 #endif
 #if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
@@ -41,8 +41,11 @@
 
 #if !defined( BOOST_EXCEPTION_DISABLE )
 # include <boost/exception/exception.hpp>
+#if !defined(BOOST_THROW_EXCEPTION_CURRENT_FUNCTION)
 # include <boost/current_function.hpp>
-# 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

Modified: branches/release/libs/exception/test/cloning_test.cpp
==============================================================================
--- branches/release/libs/exception/test/cloning_test.cpp Tue Sep 10 01:44:02 2013 (r85635)
+++ branches/release/libs/exception/test/cloning_test.cpp 2013-09-10 01:54:53 EDT (Tue, 10 Sep 2013) (r85636)
@@ -143,6 +143,8 @@
 #ifndef BOOST_NO_RTTI
             std::type_info const * const * t=boost::get_error_info<boost::original_exception_type>(x);
             BOOST_TEST(t!=0 && *t!=0 && **t==typeid(T));
+ std::string s=diagnostic_information(x);
+ BOOST_TEST(!s.empty());
 #endif
             }
         catch(

Modified: branches/release/libs/exception/test/throw_exception_test.cpp
==============================================================================
--- branches/release/libs/exception/test/throw_exception_test.cpp Tue Sep 10 01:44:02 2013 (r85635)
+++ branches/release/libs/exception/test/throw_exception_test.cpp 2013-09-10 01:54:53 EDT (Tue, 10 Sep 2013) (r85636)
@@ -35,8 +35,8 @@
     catch(
     boost::exception & x )
         {
- char const * const * file=boost::get_error_info<boost::throw_function>(x);
- char const * const * function=boost::get_error_info<boost::throw_file>(x);
+ char const * const * function=boost::get_error_info<boost::throw_function>(x);
+ char const * const * file=boost::get_error_info<boost::throw_file>(x);
         int const * line=boost::get_error_info<boost::throw_line>(x);
         BOOST_TEST( file && *file );
         BOOST_TEST( function && *function );
@@ -55,8 +55,8 @@
     catch(
     boost::exception & x )
         {
- char const * const * file=boost::get_error_info<boost::throw_function>(x);
- char const * const * function=boost::get_error_info<boost::throw_file>(x);
+ char const * const * function=boost::get_error_info<boost::throw_function>(x);
+ char const * const * file=boost::get_error_info<boost::throw_file>(x);
         int const * line=boost::get_error_info<boost::throw_line>(x);
         int const * data=boost::get_error_info<test_data>(x);
         BOOST_TEST( file && *file );


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk