Both enable_error_info.hpp and enable_current_exception.hpp now do not depend on intrusive_ptr or any other Boost lib.

[SVN r48482]
This commit is contained in:
Emil Dotchevski
2008-08-31 01:39:00 +00:00
parent f2b14ffa98
commit f12d40765b
9 changed files with 200 additions and 58 deletions

View File

@ -126,7 +126,7 @@ boost
private:
friend class boost::exception;
friend class boost::exception;
typedef std::map< type_info_, shared_ptr<error_info_base const> > error_info_map;
error_info_map info_;
@ -151,9 +151,10 @@ boost
void
set_data( exception const * e, shared_ptr<exception_detail::error_info_base const> const & x, exception_detail::type_info_ const & typeid_ )
{
if( !e->data_ )
e->data_ = intrusive_ptr<exception_detail::error_info_container>(new exception_detail::error_info_container_impl);
e->data_->set(x,typeid_);
exception_detail::error_info_container * c;
if( !(c=e->data_.get()) )
e->data_.adopt(c=new exception_detail::error_info_container_impl);
c->set(x,typeid_);
}
}