Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-31 09:41:55

0001 /*=============================================================================
0002     Copyright (c) 2009 Hartmut Kaiser
0003 
0004     Distributed under the Boost Software License, Version 1.0. (See accompanying 
0005     file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
0006 ==============================================================================*/
0007 
0008 #if !defined(BOOST_FUSION_NVIEW_AT_IMPL_SEP_24_2009_0225PM)
0009 #define BOOST_FUSION_NVIEW_AT_IMPL_SEP_24_2009_0225PM
0010 
0011 #include <boost/fusion/support/config.hpp>
0012 #include <boost/fusion/sequence/intrinsic/at.hpp>
0013 #include <boost/fusion/sequence/intrinsic/value_at.hpp>
0014 
0015 namespace boost { namespace fusion
0016 {
0017     struct nview_tag;
0018 
0019     namespace extension
0020     {
0021         template<typename Tag>
0022         struct at_impl;
0023 
0024         template<>
0025         struct at_impl<nview_tag>
0026         {
0027             template<typename Sequence, typename N>
0028             struct apply
0029             {
0030                 typedef typename Sequence::sequence_type sequence_type;
0031                 typedef typename Sequence::index_type index_type;
0032 
0033                 typedef typename result_of::value_at<index_type, N>::type index;
0034                 typedef typename result_of::at<sequence_type, index>::type type;
0035 
0036                 BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
0037                 static type
0038                 call(Sequence& seq)
0039                 {
0040                     return fusion::at<index>(seq.seq);
0041                 }
0042             };
0043         };
0044     }
0045 
0046 }}
0047 
0048 #endif