annotate DEPENDENCIES/generic/include/boost/geometry/index/detail/utilities.hpp @ 133:4acb5d8d80b6 tip

Don't fail environmental check if README.md exists (but .txt and no-suffix don't)
author Chris Cannam
date Tue, 30 Jul 2019 12:25:44 +0100
parents 2665513ce2d3
children
rev   line source
Chris@16 1 // Boost.Geometry Index
Chris@16 2 //
Chris@16 3 // Copyright (c) 2011-2013 Adam Wulkiewicz, Lodz, Poland.
Chris@16 4 //
Chris@16 5 // Use, modification and distribution is subject to the Boost Software License,
Chris@16 6 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
Chris@16 7 // http://www.boost.org/LICENSE_1_0.txt)
Chris@16 8
Chris@16 9 #include <boost/swap.hpp>
Chris@16 10 //#include <boost/type_traits/is_empty.hpp>
Chris@16 11
Chris@16 12 #ifndef BOOST_GEOMETRY_INDEX_DETAIL_UTILITIES_HPP
Chris@16 13 #define BOOST_GEOMETRY_INDEX_DETAIL_UTILITIES_HPP
Chris@16 14
Chris@16 15 namespace boost { namespace geometry { namespace index { namespace detail {
Chris@16 16
Chris@16 17 template<class T>
Chris@16 18 static inline void assign_cond(T & l, T const& r, boost::mpl::bool_<true> const&)
Chris@16 19 {
Chris@16 20 l = r;
Chris@16 21 }
Chris@16 22
Chris@16 23 template<class T>
Chris@16 24 static inline void assign_cond(T &, T const&, boost::mpl::bool_<false> const&) {}
Chris@16 25
Chris@16 26 template<class T>
Chris@16 27 static inline void move_cond(T & l, T & r, boost::mpl::bool_<true> const&)
Chris@16 28 {
Chris@16 29 l = ::boost::move(r);
Chris@16 30 }
Chris@16 31
Chris@16 32 template<class T>
Chris@16 33 static inline void move_cond(T &, T &, boost::mpl::bool_<false> const&) {}
Chris@16 34
Chris@16 35 template <typename T> inline
Chris@16 36 void swap_cond(T & l, T & r, boost::mpl::bool_<true> const&)
Chris@16 37 {
Chris@16 38 ::boost::swap(l, r);
Chris@16 39 }
Chris@16 40
Chris@16 41 template <typename T> inline
Chris@16 42 void swap_cond(T &, T &, boost::mpl::bool_<false> const&) {}
Chris@16 43
Chris@16 44 }}}} // namespace boost::geometry::index::detail
Chris@16 45
Chris@16 46 #endif // BOOST_GEOMETRY_INDEX_DETAIL_UTILITIES_HPP