x
Yes
No
Do you want to visit DriveHQ English website?
首页
产品服务
价格
免费试用
下载客户端
关于我们
云文件服务
|
云备份服务
|
FTP服务
|
企业邮箱服务
|
网站托管
|
客户端软件
云文件服务
云备份服务
FTP服务
企业级邮箱服务
网站托管
客户端软件
full_lambda.hpp - Hosted on DriveHQ Cloud IT Platform
返回上层目录
上传
下载
共享
发布
新建文件夹
新建文件
复制
剪切
删除
粘贴
评论
升级服务
路径: \\game3dprogramming\materials\GameFactory\GameFactoryDemo\references\boost_1_35_0\boost\mpl\aux_\full_lambda.hpp
旋转
特效
属性
历史版本
#if !defined(BOOST_PP_IS_ITERATING) ///// header body #ifndef BOOST_MPL_AUX_FULL_LAMBDA_HPP_INCLUDED #define BOOST_MPL_AUX_FULL_LAMBDA_HPP_INCLUDED // Copyright Aleksey Gurtovoy 2001-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) // // See http://www.boost.org/libs/mpl for documentation. // $Source$ // $Date: 2004-09-03 21:10:23 -0400 (Fri, 03 Sep 2004) $ // $Revision: 24896 $ #if !defined(BOOST_MPL_PREPROCESSING_MODE) # include
# include
# include
# include
# include
# include
# include
# include
# include
# include
# if defined(BOOST_MPL_CFG_EXTENDED_TEMPLATE_PARAMETERS_MATCHING) # include
# endif #endif #include
#include
#if !defined(BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS) \ && !defined(BOOST_MPL_PREPROCESSING_MODE) # define BOOST_MPL_PREPROCESSED_HEADER full_lambda.hpp # include
#else # include
# include
# include
# include
# include
# include
# include
# include
# include
# include
namespace boost { namespace mpl { // local macros, #undef-ined at the end of the header # define AUX778076_LAMBDA_PARAMS(i_, param) \ BOOST_MPL_PP_PARAMS(i_, param) \ /**/ # define AUX778076_BIND_PARAMS(param) \ BOOST_MPL_PP_PARAMS( \ BOOST_MPL_LIMIT_METAFUNCTION_ARITY \ , param \ ) \ /**/ # define AUX778076_BIND_N_PARAMS(i_, param) \ BOOST_PP_COMMA_IF(i_) \ BOOST_MPL_PP_PARAMS(i_, param) \ /**/ # define AUX778076_ARITY_PARAM(param) \ BOOST_MPL_AUX_LAMBDA_ARITY_PARAM(param) \ /**/ #define n_ BOOST_MPL_LIMIT_METAFUNCTION_ARITY namespace aux { template< BOOST_MPL_PP_DEFAULT_PARAMS(n_,bool C,false) > struct lambda_or : true_ { }; template<> struct lambda_or< BOOST_MPL_PP_ENUM(n_,false) > : false_ { }; } // namespace aux #undef n_ template< typename T , typename Tag AUX778076_ARITY_PARAM(typename Arity) > struct lambda { typedef false_ is_le; typedef T result_; typedef T type; }; template< typename T > struct is_lambda_expression : lambda
::is_le { }; template< int N, typename Tag > struct lambda< arg
,Tag AUX778076_ARITY_PARAM(int_<-1>) > { typedef true_ is_le; typedef mpl::arg
result_; // qualified for the sake of MIPSpro 7.41 typedef mpl::protect
type; }; #define BOOST_PP_ITERATION_PARAMS_1 \ (3,(0, BOOST_MPL_LIMIT_METAFUNCTION_ARITY,
)) #include BOOST_PP_ITERATE() /// special case for 'protect' template< typename T, typename Tag > struct lambda< mpl::protect
,Tag AUX778076_ARITY_PARAM(int_<1>) > { typedef false_ is_le; typedef mpl::protect
result_; typedef result_ type; }; /// specializations for the main 'bind' form template< typename F, AUX778076_BIND_PARAMS(typename T) , typename Tag > struct lambda< bind
, Tag AUX778076_ARITY_PARAM(int_
) > { typedef false_ is_le; typedef bind
result_; typedef result_ type; }; #if defined(BOOST_MPL_CFG_EXTENDED_TEMPLATE_PARAMETERS_MATCHING) template< typename F , typename Tag1 , typename Tag2 , typename Arity > struct lambda< lambda
, Tag2 , int_<3> > { typedef lambda< F,Tag2 > l1; typedef lambda< Tag1,Tag2 > l2; typedef typename l1::is_le is_le; typedef bind1< quote1
, typename l1::result_ > arity_; typedef lambda< typename if_
::type,Tag2 > l3; typedef aux::le_result3
le_result_; typedef typename le_result_::result_ result_; typedef typename le_result_::type type; }; #elif !defined(BOOST_MPL_CFG_DMC_AMBIGUOUS_CTPS) /// workaround for MWCW 8.3+/EDG < 303, leads to ambiguity on Digital Mars template< typename F, typename Tag1, typename Tag2 > struct lambda< lambda< F,Tag1 > , Tag2 > { typedef lambda< F,Tag2 > l1; typedef lambda< Tag1,Tag2 > l2; typedef typename l1::is_le is_le; typedef aux::le_result2
le_result_; typedef typename le_result_::result_ result_; typedef typename le_result_::type type; }; #endif # undef AUX778076_ARITY_PARAM # undef AUX778076_BIND_N_PARAMS # undef AUX778076_BIND_PARAMS # undef AUX778076_LAMBDA_PARAMS #if !defined(BOOST_MPL_CFG_EXTENDED_TEMPLATE_PARAMETERS_MATCHING) BOOST_MPL_AUX_NA_SPEC(2, lambda) #else BOOST_MPL_AUX_NA_SPEC2(2, 3, lambda) #endif }} #endif // BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS #endif // BOOST_MPL_AUX_FULL_LAMBDA_HPP_INCLUDED ///// iteration, depth == 1 #elif BOOST_PP_ITERATION_DEPTH() == 1 #define i_ BOOST_PP_FRAME_ITERATION(1) #if i_ > 0 namespace aux { # define AUX778076_RESULT(unused, i_, T) \ BOOST_PP_COMMA_IF(i_) \ typename BOOST_PP_CAT(T, BOOST_PP_INC(i_))::result_ \ /**/ # define AUX778076_TYPE(unused, i_, T) \ BOOST_PP_COMMA_IF(i_) \ typename BOOST_PP_CAT(T, BOOST_PP_INC(i_))::type \ /**/ template< typename IsLE, typename Tag , template< AUX778076_LAMBDA_PARAMS(i_, typename P) > class F , AUX778076_LAMBDA_PARAMS(i_, typename L) > struct BOOST_PP_CAT(le_result,i_) { typedef F< BOOST_MPL_PP_REPEAT(i_, AUX778076_TYPE, L) > result_; typedef result_ type; }; template< typename Tag , template< AUX778076_LAMBDA_PARAMS(i_, typename P) > class F , AUX778076_LAMBDA_PARAMS(i_, typename L) > struct BOOST_PP_CAT(le_result,i_)< true_,Tag,F,AUX778076_LAMBDA_PARAMS(i_, L) > { typedef BOOST_PP_CAT(bind,i_)< BOOST_PP_CAT(quote,i_)
, BOOST_MPL_PP_REPEAT(i_, AUX778076_RESULT, L) > result_; typedef mpl::protect
type; }; # undef AUX778076_TYPE # undef AUX778076_RESULT } // namespace aux # define AUX778076_LAMBDA_TYPEDEF(unused, i_, T) \ typedef lambda< BOOST_PP_CAT(T, BOOST_PP_INC(i_)), Tag > \ BOOST_PP_CAT(l,BOOST_PP_INC(i_)); \ /**/ # define AUX778076_IS_LE_TYPEDEF(unused, i_, unused2) \ typedef typename BOOST_PP_CAT(l,BOOST_PP_INC(i_))::is_le \ BOOST_PP_CAT(is_le,BOOST_PP_INC(i_)); \ /**/ # define AUX778076_IS_LAMBDA_EXPR(unused, i_, unused2) \ BOOST_PP_COMMA_IF(i_) \ BOOST_PP_CAT(is_le,BOOST_PP_INC(i_))::value \ /**/ template< template< AUX778076_LAMBDA_PARAMS(i_, typename P) > class F , AUX778076_LAMBDA_PARAMS(i_, typename T) , typename Tag > struct lambda< F
, Tag AUX778076_ARITY_PARAM(int_
) > { BOOST_MPL_PP_REPEAT(i_, AUX778076_LAMBDA_TYPEDEF, T) BOOST_MPL_PP_REPEAT(i_, AUX778076_IS_LE_TYPEDEF, unused) typedef typename aux::lambda_or< BOOST_MPL_PP_REPEAT(i_, AUX778076_IS_LAMBDA_EXPR, unused) >::type is_le; typedef aux::BOOST_PP_CAT(le_result,i_)< is_le, Tag, F, AUX778076_LAMBDA_PARAMS(i_, l) > le_result_; typedef typename le_result_::result_ result_; typedef typename le_result_::type type; }; # undef AUX778076_IS_LAMBDA_EXPR # undef AUX778076_IS_LE_TYPEDEF # undef AUX778076_LAMBDA_TYPEDEF #endif // i_ > 0 template< typename F AUX778076_BIND_N_PARAMS(i_, typename T) , typename Tag > struct lambda< BOOST_PP_CAT(bind,i_)
, Tag AUX778076_ARITY_PARAM(int_
) > { typedef false_ is_le; typedef BOOST_PP_CAT(bind,i_)< F AUX778076_BIND_N_PARAMS(i_, T) > result_; typedef result_ type; }; #undef i_ #endif // BOOST_PP_IS_ITERATING
full_lambda.hpp
网页地址
文件地址
上一页
29/93
下一页
下载
( 8 KB )
Comments
Total ratings:
0
Average rating:
无评论
of 10
Would you like to comment?
Join now
, or
Logon
if you are already a member.