merge new MPL version from 'mplbook' branch

[SVN r24874]
This commit is contained in:
Aleksey Gurtovoy
2004-09-02 15:41:37 +00:00
parent 3cdf8c8ed2
commit 8f2d14c5c9
16 changed files with 115 additions and 127 deletions

View File

@ -20,7 +20,7 @@
#include "boost/type_traits/alignment_of.hpp"
#include "boost/type_traits/type_with_alignment.hpp"
#include "boost/mpl/apply_if.hpp"
#include "boost/mpl/eval_if.hpp"
#include "boost/mpl/identity.hpp"
namespace boost {
@ -46,7 +46,7 @@ private: // representation
{
char buf[size_];
typename mpl::apply_if_c<
typename mpl::eval_if_c<
alignment_ == std::size_t(-1)
, mpl::identity<detail::max_align>
, type_with_alignment<alignment_>

View File

@ -1,5 +1,5 @@
// Copyright (c) 2001-2003 Aleksey Gurtovoy.
// Copyright 2001-2003 Aleksey Gurtovoy.
// Use, modification and distribution are subject to 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).

View File

@ -1,7 +1,7 @@
// Copyright (C) 2000 John Maddock (john@johnmaddock.co.uk)
// Copyright (C) 2000 Jeremy Siek (jsiek@lsc.nd.edu)
// Copyright (C) 1999, 2000 Jaakko J<>rvi (jaakko.jarvi@cs.utu.fi)
// Copyright 2000 John Maddock (john@johnmaddock.co.uk)
// Copyright 2000 Jeremy Siek (jsiek@lsc.nd.edu)
// Copyright 1999, 2000 Jaakko J<>rvi (jaakko.jarvi@cs.utu.fi)
//
// Use, modification and distribution are subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at

View File

@ -1,25 +1,24 @@
//-----------------------------------------------------------------------------
// boost/type_traits/detail/bool_trait_def.hpp header file
// See http://www.boost.org for updates, documentation, and revision history.
//-----------------------------------------------------------------------------
//
// Copyright (c) 2002
// Aleksey Gurtovoy
//
// Use, modification and distribution are subject to 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).
// no include guards, the header is intended for multiple inclusion!
// NO INCLUDE GUARDS, THE HEADER IS INTENDED FOR MULTIPLE INCLUSION
#include "boost/type_traits/detail/template_arity_spec.hpp"
#include "boost/mpl/bool.hpp"
#include "boost/mpl/aux_/lambda_support.hpp"
#include "boost/config.hpp"
// Copyright Aleksey Gurtovoy 2002-2004
//
// 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)
// $Source$
// $Date$
// $Revision$
#include <boost/type_traits/detail/template_arity_spec.hpp>
#include <boost/mpl/bool.hpp>
#include <boost/mpl/aux_/lambda_support.hpp>
#include <boost/config.hpp>
#if defined(__SUNPRO_CC)
# define BOOST_TT_AUX_BOOL_TRAIT_VALUE_DECL(C) \
typedef mpl::bool_< C > type; \
typedef BOOST_MPL_AUX_ADL_BARRIER_NAMESPACE::bool_< C > type; \
enum { value = type::value }; \
/**/
# define BOOST_TT_AUX_BOOL_C_BASE(C)
@ -27,7 +26,7 @@
#elif defined(BOOST_MSVC) && BOOST_MSVC <= 1200
# define BOOST_TT_AUX_BOOL_TRAIT_VALUE_DECL(C) \
typedef mpl::bool_< C > base_; \
typedef BOOST_MPL_AUX_ADL_BARRIER_NAMESPACE::bool_< C > base_; \
using base_::value; \
/**/
@ -38,7 +37,7 @@
#endif
#ifndef BOOST_TT_AUX_BOOL_C_BASE
# define BOOST_TT_AUX_BOOL_C_BASE(C) : mpl::bool_< C >
# define BOOST_TT_AUX_BOOL_C_BASE(C) : BOOST_MPL_AUX_ADL_BARRIER_NAMESPACE::bool_< C >
#endif
@ -167,7 +166,7 @@ namespace boost{
template <class T, T val>
struct integral_constant
: public mpl::integral_c<T,val> {};
: public BOOST_MPL_AUX_ADL_BARRIER_NAMESPACE::integral_c<T,val> {};
template<> struct integral_constant< bool, true > \
@ -184,8 +183,8 @@ template<> struct integral_constant< bool, false > \
};
namespace pending {
typedef mpl::true_ true_type;
typedef mpl::false_ false_type;
typedef BOOST_MPL_AUX_ADL_BARRIER_NAMESPACE::true_ true_type;
typedef BOOST_MPL_AUX_ADL_BARRIER_NAMESPACE::false_ false_type;
}
}

View File

@ -1,17 +1,15 @@
//-----------------------------------------------------------------------------
// boost/type_traits/detail/bool_trait_undef.hpp header file
//-----------------------------------------------------------------------------
//
// Copyright (c) 2002
// Aleksey Gurtovoy
//
// Use, modification and distribution are subject to 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).
//
// See http://www.boost.org/libs/type_traits for most recent version including documentation.
// no include guards, the header is intended for multiple inclusion!
// NO INCLUDE GUARDS, THE HEADER IS INTENDED FOR MULTIPLE INCLUSION
// Copyright Aleksey Gurtovoy 2002-2004
//
// 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)
// $Source$
// $Date$
// $Revision$
#undef BOOST_TT_AUX_BOOL_TRAIT_VALUE_DECL
#undef BOOST_TT_AUX_BOOL_C_BASE

View File

@ -1,6 +1,6 @@
// Copyright (C) 2000 John Maddock (john@johnmaddock.co.uk)
// Copyright (C) 2002 Aleksey Gurtovoy (agurtovoy@meta-comm.com)
// Copyright 2000 John Maddock (john@johnmaddock.co.uk)
// Copyright 2002 Aleksey Gurtovoy (agurtovoy@meta-comm.com)
//
// Use, modification and distribution are subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at

View File

@ -343,7 +343,7 @@ template <class R, class T BOOST_PP_COMMA_IF(i) BOOST_PP_ENUM_PARAMS(i,class T)>
struct is_mem_fun_pointer_impl<R (T::*)(BOOST_PP_ENUM_PARAMS(i,T)) > { BOOST_STATIC_CONSTANT(bool, value = true); };
// Metrowerks and Visual Age think this creates ambiguities
//: #if !((defined(__MWERKS__) && __MWERKS__ < 0x3000) || (defined(__IBMCPP__) && __IBMCPP__ <= 600))
/// #if !((defined(__MWERKS__) && __MWERKS__ < 0x3000) || (defined(__IBMCPP__) && __IBMCPP__ <= 600))
template <class R, class T BOOST_PP_COMMA_IF(i) BOOST_PP_ENUM_PARAMS(i,class T)>
struct is_mem_fun_pointer_impl<R (T::*)(BOOST_PP_ENUM_PARAMS(i,T)) const > { BOOST_STATIC_CONSTANT(bool, value = true); };
@ -352,7 +352,7 @@ struct is_mem_fun_pointer_impl<R (T::*)(BOOST_PP_ENUM_PARAMS(i,T)) volatile > {
template <class R, class T BOOST_PP_COMMA_IF(i) BOOST_PP_ENUM_PARAMS(i,class T)>
struct is_mem_fun_pointer_impl<R (T::*)(BOOST_PP_ENUM_PARAMS(i,T)) const volatile > { BOOST_STATIC_CONSTANT(bool, value = true); };
//: #endif
/// #endif
#undef i

View File

@ -1,20 +1,19 @@
//-----------------------------------------------------------------------------
// boost/type_traits/detail/size_t_trait_def.hpp header file
// See http://www.boost.org for updates, documentation, and revision history.
//-----------------------------------------------------------------------------
//
// Copyright (c) 2002
// Aleksey Gurtovoy
//
// Use, modification and distribution are subject to 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).
// no include guards, the header is intended for multiple inclusion!
// NO INCLUDE GUARDS, THE HEADER IS INTENDED FOR MULTIPLE INCLUSION
#include "boost/type_traits/detail/template_arity_spec.hpp"
#include "boost/mpl/size_t.hpp"
#include "boost/mpl/aux_/lambda_support.hpp"
// Copyright Aleksey Gurtovoy 2002-2004
//
// 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)
// $Source$
// $Date$
// $Revision$
#include <boost/type_traits/detail/template_arity_spec.hpp>
#include <boost/mpl/size_t.hpp>
#include <boost/mpl/aux_/lambda_support.hpp>
#include <cstddef>

View File

@ -1,16 +1,15 @@
//-----------------------------------------------------------------------------
// boost/type_traits/detail/size_t_trait_undef.hpp header file
// See http://www.boost.org for updates, documentation, and revision history.
//-----------------------------------------------------------------------------
//
// Copyright (c) 2002
// Aleksey Gurtovoy
//
// Use, modification and distribution are subject to 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).
// no include guards, the header is intended for multiple inclusion!
// NO INCLUDE GUARDS, THE HEADER IS INTENDED FOR MULTIPLE INCLUSION
// Copyright Aleksey Gurtovoy 2002-2004
//
// 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)
// $Source$
// $Date$
// $Revision$
#undef BOOST_TT_AUX_SIZE_T_TRAIT_DEF1
#undef BOOST_TT_AUX_SIZE_T_TRAIT_SPEC1

View File

@ -1,33 +1,28 @@
//-----------------------------------------------------------------------------
// boost/type_traits/detail/template_arity_spec.hpp header file
// See http://www.boost.org for updates, documentation, and revision history.
//-----------------------------------------------------------------------------
// NO INCLUDE GUARDS, THE HEADER IS INTENDED FOR MULTIPLE INCLUSION
// Copyright Aleksey Gurtovoy 2002-2004
//
// Copyright (c) 2002
// Aleksey Gurtovoy
//
// Use, modification and distribution are subject to 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).
// 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)
// no include guards, the header is intended for multiple inclusion!
#include <boost/mpl/int.hpp>
#include <boost/mpl/aux_/template_arity_fwd.hpp>
#include <boost/mpl/aux_/preprocessor/params.hpp>
#include <boost/mpl/aux_/config/lambda.hpp>
#include <boost/mpl/aux_/config/overload_resolution.hpp>
#include "boost/mpl/aux_/template_arity_fwd.hpp"
#include "boost/mpl/aux_/preprocessor/params.hpp"
#include "boost/mpl/aux_/lambda_support.hpp"
#include "boost/mpl/aux_/config/overload_resolution.hpp"
#include "boost/config.hpp"
#if defined(BOOST_MPL_NO_FULL_LAMBDA_SUPPORT) && \
defined(BOOST_MPL_BROKEN_OVERLOAD_RESOLUTION)
#if defined(BOOST_MPL_CFG_NO_FULL_LAMBDA_SUPPORT) \
&& defined(BOOST_MPL_CFG_BROKEN_OVERLOAD_RESOLUTION)
# define BOOST_TT_AUX_TEMPLATE_ARITY_SPEC(i, name) \
namespace mpl { namespace aux { \
template< BOOST_MPL_PP_PARAMS(i, typename T) > \
struct template_arity< \
name< BOOST_MPL_PP_PARAMS(i, T) > \
> \
name< BOOST_MPL_PP_PARAMS(i, T) > \
> \
: int_<i> \
{ \
BOOST_STATIC_CONSTANT(int, value = i ); \
}; \
}} \
/**/

View File

@ -1,19 +1,18 @@
//-----------------------------------------------------------------------------
// boost/type_traits/detail/type_trait_def.hpp header file
// See http://www.boost.org for updates, documentation, and revision history.
//-----------------------------------------------------------------------------
//
// Copyright (c) 2002
// Aleksey Gurtovoy
//
// Use, modification and distribution are subject to 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).
// no include guards, the header is intended for multiple inclusion!
// NO INCLUDE GUARDS, THE HEADER IS INTENDED FOR MULTIPLE INCLUSION
#include "boost/type_traits/detail/template_arity_spec.hpp"
#include "boost/mpl/aux_/lambda_support.hpp"
// Copyright Aleksey Gurtovoy 2002-2004
//
// 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)
// $Source$
// $Date$
// $Revision$
#include <boost/type_traits/detail/template_arity_spec.hpp>
#include <boost/mpl/aux_/lambda_support.hpp>
#define BOOST_TT_AUX_TYPE_TRAIT_DEF1(trait,T,result) \
template< typename T > struct trait \

View File

@ -1,16 +1,15 @@
//-----------------------------------------------------------------------------
// boost/type_traits/detail/type_trait_undef.hpp header file
// See http://www.boost.org for updates, documentation, and revision history.
//-----------------------------------------------------------------------------
//
// Copyright (c) 2002
// Aleksey Gurtovoy
//
// Use, modification and distribution are subject to 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).
// no include guards, the header is intended for multiple inclusion!
// NO INCLUDE GUARDS, THE HEADER IS INTENDED FOR MULTIPLE INCLUSION
// Copyright Aleksey Gurtovoy 2002-2004
//
// 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)
// $Source$
// $Date$
// $Revision$
#undef BOOST_TT_AUX_TYPE_TRAIT_DEF1
#undef BOOST_TT_AUX_TYPE_TRAIT_SPEC1

View File

@ -1,5 +1,5 @@
// Copyright (C) 2000 John Maddock (john@johnmaddock.co.uk)
// Copyright 2000 John Maddock (john@johnmaddock.co.uk)
// Use, modification and distribution are subject to 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).

View File

@ -1,7 +1,7 @@
// Copyright (C) 2000 John Maddock (john@johnmaddock.co.uk)
// Copyright (C) 2000 Jeremy Siek (jsiek@lsc.nd.edu)
// Copyright (C) 1999, 2000 Jaakko J<>rvi (jaakko.jarvi@cs.utu.fi)
// Copyright 2000 John Maddock (john@johnmaddock.co.uk)
// Copyright 2000 Jeremy Siek (jsiek@lsc.nd.edu)
// Copyright 1999, 2000 Jaakko J<>rvi (jaakko.jarvi@cs.utu.fi)
//
// Use, modification and distribution are subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at

View File

@ -1,6 +1,6 @@
// Copyright (C) 2000 John Maddock (john@johnmaddock.co.uk)
// Copyright (C) 2002 Aleksey Gurtovoy (agurtovoy@meta-comm.com)
// Copyright 2000 John Maddock (john@johnmaddock.co.uk)
// Copyright 2002 Aleksey Gurtovoy (agurtovoy@meta-comm.com)
//
// Use, modification and distribution are subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at

View File

@ -1,5 +1,5 @@
// Copyright (c) 2001 Aleksey Gurtovoy.
// Copyright 2001 Aleksey Gurtovoy.
// Use, modification and distribution are subject to 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).