epoc32/include/stdapis/boost/ptr_container/detail/throw_exception.hpp
branchSymbian3
changeset 4 837f303aceeb
parent 3 e1b950c65cb4
     1.1 --- a/epoc32/include/stdapis/boost/ptr_container/detail/throw_exception.hpp	Wed Mar 31 12:27:01 2010 +0100
     1.2 +++ b/epoc32/include/stdapis/boost/ptr_container/detail/throw_exception.hpp	Wed Mar 31 12:33:34 2010 +0100
     1.3 @@ -1,46 +1,33 @@
     1.4 -#ifndef BOOST_THROW_EXCEPTION_HPP_INCLUDED
     1.5 -#define BOOST_THROW_EXCEPTION_HPP_INCLUDED
     1.6 -
     1.7 -// MS compatible compilers support #pragma once
     1.8 -
     1.9 -#if defined(_MSC_VER) && (_MSC_VER >= 1020)
    1.10 -# pragma once
    1.11 -#endif
    1.12 -
    1.13  //
    1.14 -//  boost/throw_exception.hpp
    1.15 +// Boost.Pointer Container
    1.16  //
    1.17 -//  Copyright (c) 2002 Peter Dimov and Multi Media Ltd.
    1.18 +//  Copyright Thorsten Ottosen 2006. Use, modification and
    1.19 +//  distribution is subject to the Boost Software License, Version
    1.20 +//  1.0. (See accompanying file LICENSE_1_0.txt or copy at
    1.21 +//  http://www.boost.org/LICENSE_1_0.txt)
    1.22  //
    1.23 -// Distributed under the Boost Software License, Version 1.0. (See
    1.24 -// accompanying file LICENSE_1_0.txt or copy at
    1.25 -// http://www.boost.org/LICENSE_1_0.txt)
    1.26 -//
    1.27 -//  http://www.boost.org/libs/utility/throw_exception.html
    1.28 +// For more information, see http://www.boost.org/libs/ptr_container/
    1.29  //
    1.30  
    1.31 +#ifndef BOOST_PTR_CONTAINER_DETAIL_THROW_EXCEPTION
    1.32 +#define BOOST_PTR_CONTAINER_DETAIL_THROW_EXCEPTION
    1.33 +
    1.34 +#include <boost/assert.hpp>
    1.35  #include <boost/config.hpp>
    1.36  
    1.37  #ifdef BOOST_NO_EXCEPTIONS
    1.38 -# include <exception>
    1.39 +#define BOOST_PTR_CONTAINER_NO_EXCEPTIONS
    1.40  #endif
    1.41  
    1.42 -namespace boost
    1.43 -{
    1.44 +#ifdef BOOST_PTR_CONTAINER_NO_EXCEPTIONS
    1.45  
    1.46 -#ifdef BOOST_NO_EXCEPTIONS
    1.47 -
    1.48 -void throw_exception(std::exception const & e); // user defined
    1.49 +#define BOOST_PTR_CONTAINER_THROW_EXCEPTION( If, Ex, Msg ) BOOST_ASSERT( !(If) && Msg ) 
    1.50  
    1.51  #else
    1.52  
    1.53 -template<class E> inline void throw_exception(E const & e)
    1.54 -{
    1.55 -    throw e;
    1.56 -}
    1.57 +#define BOOST_PTR_CONTAINER_THROW_EXCEPTION( If, Ex, Msg ) if( (If) ) throw Ex ( Msg )
    1.58 +
    1.59 +#endif // BOOST_PTR_CONTAINER_NO_EXCEPTIONS
    1.60 +
    1.61  
    1.62  #endif
    1.63 -
    1.64 -} // namespace boost
    1.65 -
    1.66 -#endif // #ifndef BOOST_THROW_EXCEPTION_HPP_INCLUDED