Sha256: 9244c77f070bee587fed9195f532eb76ec1a6f653036f996f983efeb81e3e59c

Contents?: true

Size: 1.61 KB

Versions: 55

Compression:

Stored size: 1.61 KB

Contents

/////////////////////////////////////////////////////////////////////////////
//
// (C) Copyright Ion Gaztanaga  2006-2014
//
// 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/intrusive for documentation.
//
/////////////////////////////////////////////////////////////////////////////

#ifndef BOOST_INTRUSIVE_DETAIL_UNCAST_HPP
#define BOOST_INTRUSIVE_DETAIL_UNCAST_HPP

#ifndef BOOST_CONFIG_HPP
#  include <boost/config.hpp>
#endif

#if defined(BOOST_HAS_PRAGMA_ONCE)
#  pragma once
#endif

#include <boost/intrusive/detail/config_begin.hpp>
#include <boost/intrusive/pointer_traits.hpp>
#include <boost/intrusive/detail/mpl.hpp>

namespace boost {
namespace intrusive {
namespace detail {

template<class ConstNodePtr>
struct uncast_types
{
   typedef typename pointer_traits<ConstNodePtr>::element_type element_type;
   typedef typename remove_const<element_type>::type           non_const_type;
   typedef typename pointer_traits<ConstNodePtr>::
      template rebind_pointer<non_const_type>::type            non_const_pointer;
   typedef pointer_traits<non_const_pointer>                   non_const_traits;
};

template<class ConstNodePtr>
static typename uncast_types<ConstNodePtr>::non_const_pointer
   uncast(const ConstNodePtr & ptr)
{
   return uncast_types<ConstNodePtr>::non_const_traits::const_cast_from(ptr);
}

} //namespace detail {
} //namespace intrusive
} //namespace boost

#include <boost/intrusive/detail/config_end.hpp>

#endif //BOOST_INTRUSIVE_DETAIL_UTILITIES_HPP

Version data entries

55 entries across 55 versions & 2 rubygems

Version Path
passenger-6.0.24 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.23 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.20 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.19 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.18 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.17 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.16 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.15 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.14 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.13 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.12 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.11 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.10 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.9 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.8 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.7 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.6 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.5 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.4 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp
passenger-6.0.3 src/cxx_supportlib/vendor-modified/boost/intrusive/detail/uncast.hpp