Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r50887 - in trunk/boost: . exception
From: emil_at_[hidden]
Date: 2009-01-29 19:06:02


Author: emildotchevski
Date: 2009-01-29 19:06:01 EST (Thu, 29 Jan 2009)
New Revision: 50887
URL: http://svn.boost.org/trac/boost/changeset/50887

Log:
added #error in headers incompatible with BOOST_NO_EXCEPTIONS
Text files modified:
   trunk/boost/exception.hpp | 2 ++
   trunk/boost/exception/diagnostic_information.hpp | 5 +++++
   trunk/boost/exception_ptr.hpp | 4 ++++
   3 files changed, 11 insertions(+), 0 deletions(-)

Modified: trunk/boost/exception.hpp
==============================================================================
--- trunk/boost/exception.hpp (original)
+++ trunk/boost/exception.hpp 2009-01-29 19:06:01 EST (Thu, 29 Jan 2009)
@@ -12,6 +12,8 @@
 #include <boost/exception/get_error_info.hpp>
 #include <boost/exception/info.hpp>
 #include <boost/exception/info_tuple.hpp>
+#ifndef BOOST_NO_EXCEPTIONS
 #include <boost/exception_ptr.hpp>
+#endif
 
 #endif

Modified: trunk/boost/exception/diagnostic_information.hpp
==============================================================================
--- trunk/boost/exception/diagnostic_information.hpp (original)
+++ trunk/boost/exception/diagnostic_information.hpp 2009-01-29 19:06:01 EST (Thu, 29 Jan 2009)
@@ -6,6 +6,7 @@
 #ifndef UUID_0552D49838DD11DD90146B8956D89593
 #define UUID_0552D49838DD11DD90146B8956D89593
 
+#include <boost/config.hpp>
 #include <boost/exception/get_error_info.hpp>
 #include <exception>
 #include <sstream>
@@ -22,13 +23,17 @@
         get_diagnostic_information( exception const & x )
             {
             if( error_info_container * c=x.data_.get() )
+#ifndef BOOST_NO_EXCEPTIONS
                 try
                     {
+#endif
                     return c->diagnostic_information();
+#ifndef BOOST_NO_EXCEPTIONS
                     }
                 catch(...)
                     {
                     }
+#endif
             return 0;
             }
         }

Modified: trunk/boost/exception_ptr.hpp
==============================================================================
--- trunk/boost/exception_ptr.hpp (original)
+++ trunk/boost/exception_ptr.hpp 2009-01-29 19:06:01 EST (Thu, 29 Jan 2009)
@@ -6,6 +6,10 @@
 #ifndef UUID_FA5836A2CADA11DC8CD47C8555D89593
 #define UUID_FA5836A2CADA11DC8CD47C8555D89593
 
+#include <boost/config.hpp>
+#ifdef BOOST_NO_EXCEPTIONS
+#error This header requires exception handling to be enabled.
+#endif
 #include <boost/exception/exception.hpp>
 #include <boost/exception/detail/type_info.hpp>
 #include <boost/shared_ptr.hpp>


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