Boost logo

Boost-Commit :

From: emil_at_[hidden]
Date: 2008-09-02 19:13:07


Author: emildotchevski
Date: 2008-09-02 19:13:06 EDT (Tue, 02 Sep 2008)
New Revision: 48551
URL: http://svn.boost.org/trac/boost/changeset/48551

Log:
bug fix in the decoupling of info.hpp from get_error_info.hpp.
Added:
   trunk/boost/exception/detail/error_info_impl.hpp (contents, props changed)
      - copied, changed from r48538, /trunk/boost/exception/detail/error_info_base.hpp
Removed:
   trunk/boost/exception/detail/error_info_base.hpp
Text files modified:
   trunk/boost/exception/detail/error_info_impl.hpp | 26 ++++++++++++++++
   trunk/boost/exception/get_error_info.hpp | 2
   trunk/boost/exception/info.hpp | 64 +++++++++++++++++----------------------
   3 files changed, 55 insertions(+), 37 deletions(-)

Deleted: trunk/boost/exception/detail/error_info_base.hpp
==============================================================================
--- trunk/boost/exception/detail/error_info_base.hpp 2008-09-02 19:13:06 EDT (Tue, 02 Sep 2008)
+++ (empty file)
@@ -1,35 +0,0 @@
-//Copyright (c) 2006-2008 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_CE6983AC753411DDA764247956D89593
-#define UUID_CE6983AC753411DDA764247956D89593
-
-#include <string>
-
-namespace
-boost
- {
- namespace
- exception_detail
- {
- class
- error_info_base
- {
- public:
-
- virtual char const * tag_typeid_name() const = 0;
- virtual std::string value_as_string() const = 0;
-
- protected:
-
- virtual
- ~error_info_base() throw()
- {
- }
- };
- }
- }
-
-#endif

Copied: trunk/boost/exception/detail/error_info_impl.hpp (from r48538, /trunk/boost/exception/detail/error_info_base.hpp)
==============================================================================
--- /trunk/boost/exception/detail/error_info_base.hpp (original)
+++ trunk/boost/exception/detail/error_info_impl.hpp 2008-09-02 19:13:06 EDT (Tue, 02 Sep 2008)
@@ -30,6 +30,32 @@
                 }
             };
         }
+
+ template <class Tag,class T>
+ class
+ error_info:
+ public exception_detail::error_info_base
+ {
+ public:
+
+ typedef T value_type;
+
+ error_info( value_type const & value );
+ ~error_info() throw();
+
+ value_type const &
+ value() const
+ {
+ return value_;
+ }
+
+ private:
+
+ char const * tag_typeid_name() const;
+ std::string value_as_string() const;
+
+ value_type const value_;
+ };
     }
 
 #endif

Modified: trunk/boost/exception/get_error_info.hpp
==============================================================================
--- trunk/boost/exception/get_error_info.hpp (original)
+++ trunk/boost/exception/get_error_info.hpp 2008-09-02 19:13:06 EDT (Tue, 02 Sep 2008)
@@ -7,7 +7,7 @@
 #define UUID_1A590226753311DD9E4CCF6156D89593
 
 #include <boost/exception/exception.hpp>
-#include <boost/exception/detail/error_info_base.hpp>
+#include <boost/exception/detail/error_info_impl.hpp>
 #include <boost/exception/detail/type_info.hpp>
 #include <boost/shared_ptr.hpp>
 #include <string.h>

Modified: trunk/boost/exception/info.hpp
==============================================================================
--- trunk/boost/exception/info.hpp (original)
+++ trunk/boost/exception/info.hpp 2008-09-02 19:13:06 EDT (Tue, 02 Sep 2008)
@@ -8,7 +8,7 @@
 
 #include <boost/exception/exception.hpp>
 #include <boost/exception/to_string_stub.hpp>
-#include <boost/exception/detail/error_info_base.hpp>
+#include <boost/exception/detail/error_info_impl.hpp>
 #include <boost/shared_ptr.hpp>
 #include <map>
 
@@ -16,45 +16,37 @@
 boost
     {
     template <class Tag,class T>
- class
- error_info:
- public exception_detail::error_info_base
+ inline
+ error_info<Tag,T>::
+ error_info( value_type const & value ):
+ value_(value)
         {
- public:
-
- typedef T value_type;
-
- error_info( value_type const & value ):
- value_(value)
- {
- }
-
- ~error_info() throw()
- {
- }
-
- value_type const &
- value() const
- {
- return value_;
- }
-
- private:
+ }
 
- char const *
- tag_typeid_name() const
- {
- return type_name<Tag>();
- }
+ template <class Tag,class T>
+ inline
+ error_info<Tag,T>::
+ ~error_info() throw()
+ {
+ }
 
- std::string
- value_as_string() const
- {
- return to_string_stub(value_);
- }
+ template <class Tag,class T>
+ inline
+ char const *
+ error_info<Tag,T>::
+ tag_typeid_name() const
+ {
+ return type_name<Tag>();
+ }
 
- value_type const value_;
- };
+ template <class Tag,class T>
+ inline
+ std::string
+ error_info<Tag,T>::
+ value_as_string() const
+ {
+ return to_string_stub(value_);
+ }
 
     namespace
     exception_detail


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