annotate DEPENDENCIES/generic/include/boost/ptr_container/detail/move.hpp @ 125:34e428693f5d vext

Vext -> Repoint
author Chris Cannam
date Thu, 14 Jun 2018 11:15:39 +0100
parents 2665513ce2d3
children
rev   line source
Chris@16 1 // (C) Copyright Daniel Wallin 2004.
Chris@16 2 // Distributed under the Boost Software License, Version 1.0. (See accompanying
Chris@16 3 // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt.)
Chris@16 4
Chris@16 5 // Contains the definitions of the class template move_source and the function
Chris@16 6 // template move, which together make move pointers moveable.
Chris@16 7
Chris@16 8 #ifndef BOOST_MOVE_HPP_INCLUDED
Chris@16 9 #define BOOST_MOVE_HPP_INCLUDED
Chris@16 10
Chris@16 11 namespace boost { namespace ptr_container_detail {
Chris@16 12
Chris@16 13 namespace move_ptrs {
Chris@16 14
Chris@16 15 #if BOOST_WORKAROUND(BOOST_MSVC, >= 1400)
Chris@16 16 #pragma warning(push)
Chris@16 17 #pragma warning(disable:4512)
Chris@16 18 #endif
Chris@16 19
Chris@16 20 template<typename Ptr>
Chris@16 21 class move_source {
Chris@16 22 public:
Chris@16 23 move_source(Ptr& ptr) : ptr_(ptr) {}
Chris@16 24 Ptr& ptr() const { return ptr_; }
Chris@16 25 private:
Chris@16 26 Ptr& ptr_;
Chris@16 27 move_source(const Ptr&);
Chris@16 28 };
Chris@16 29
Chris@16 30 #if BOOST_WORKAROUND(BOOST_MSVC, >= 1400)
Chris@16 31 #pragma warning(pop)
Chris@16 32 #endif
Chris@16 33
Chris@16 34 } // End namespace move_ptrs.
Chris@16 35
Chris@16 36
Chris@16 37 template<typename T>
Chris@16 38 move_ptrs::move_source<T> move(T& x)
Chris@16 39 { return move_ptrs::move_source<T>(x); }
Chris@16 40
Chris@16 41 } // namespace 'ptr_container_detail'
Chris@16 42 } // End namespace boost.
Chris@16 43
Chris@16 44 #endif // #ifndef BOOST_MOVE_HPP_INCLUDED