Silicium
move_if_noexcept.hpp
Go to the documentation of this file.
1 #ifndef SILICIUM_MOVE_IF_NOEXCEPT_HPP
2 #define SILICIUM_MOVE_IF_NOEXCEPT_HPP
3 
4 #include <silicium/config.hpp>
5 #include <utility>
6 
7 namespace Si
8 {
9 #if defined(__GNUC__) && (((__GNUC__ * 100) + __GNUC_MINOR__) >= 407) || defined(__clang__) || defined(_MSC_VER)
11 #else
12  template <class T, class Result = typename std::conditional<
14  const T &,
15  T &&
16  >::type>
17  BOOST_CONSTEXPR Result move_if_noexcept(T &x)
18  {
19  return static_cast<Result>(x);
20  }
21 #endif
22 }
23 
24 #endif
Definition: absolute_path.hpp:19
BOOST_CONSTEXPR Result move_if_noexcept(T &x)
Definition: move_if_noexcept.hpp:17
Definition: config.hpp:269
Definition: config.hpp:234