Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:31:07

0001 /*=============================================================================
0002     Copyright (c) 2001-2009 Joel de Guzman
0003     Copyright (c) 2005-2006 Dan Marsden
0004     Copyright (c) 2010 Christopher Schmidt
0005 
0006     Distributed under the Boost Software License, Version 1.0. (See accompanying
0007     file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
0008 ==============================================================================*/
0009 
0010 #ifndef BOOST_FUSION_ADAPTED_ADT_DETAIL_EXTENSION_HPP
0011 #define BOOST_FUSION_ADAPTED_ADT_DETAIL_EXTENSION_HPP
0012 
0013 #include <boost/fusion/support/config.hpp>
0014 #include <boost/type_traits/remove_const.hpp>
0015 #include <boost/type_traits/remove_reference.hpp>
0016 #include <boost/fusion/support/as_const.hpp>
0017 #include <boost/fusion/adapted/struct/detail/extension.hpp>
0018 
0019 namespace boost { namespace fusion
0020 {
0021     namespace detail
0022     {
0023         template <typename T, typename Dummy>
0024         struct get_identity
0025           : remove_const<typename remove_reference<T>::type>
0026         {};
0027     }
0028 
0029     namespace extension
0030     {
0031         // Overload as_const() to unwrap adt_attribute_proxy.
0032         template <typename T, int N, bool Const>
0033         BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
0034         typename adt_attribute_proxy<T, N, Const>::type as_const(const adt_attribute_proxy<T, N, Const>& proxy)
0035         {
0036             return proxy.get();
0037         }
0038     }
0039 }}
0040 
0041 #endif