Skip to content

Commit c26b2e0

Browse files
committed
Btter detection of move semantics
1 parent 8177c3e commit c26b2e0

1 file changed

Lines changed: 9 additions & 3 deletions

File tree

include/gfx/timsort.hpp

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,13 +48,19 @@
4848
#ifdef GFX_TIMSORT_DISABLE_STD_MOVE
4949
# define GFX_TIMSORT_ENABLED_STD_MOVE 0
5050
# undef GFX_TIMSORT_DISABLE_STD_MOVE
51-
#else
52-
# if (defined(_MSC_VER) && _MSC_VER >= 1700) || ((defined(__cplusplus) && __cplusplus >= 201103L && !defined(_LIBCPP_VERSION)) && ((!defined(__GNUC__) || __GNUC__ >= 5)) && (!defined(__GLIBCXX__) || __GLIBCXX__ >= 20150422))
51+
#elif !defined(GFX_TIMSORT_ENABLED_STD_MOVE)
52+
# if !(defined(__cplusplus) && __cplusplus >= 201103L)
53+
# define GFX_TIMSORT_ENABLED_STD_MOVE 0
54+
# elif defined(_MSC_VER) && _MSC_VER >= 1700
55+
# define GFX_TIMSORT_ENABLED_STD_MOVE 1
56+
# elif defined(__CLANG__)
57+
# define GFX_TIMSORT_ENABLED_STD_MOVE 1
58+
# elif defined(__GNUC__) && (__GNUC__ >= 5 || (__GNUC__ >= 4 && __GNUC_MINOR__ >= 6))
5359
# define GFX_TIMSORT_ENABLED_STD_MOVE 1
5460
# else
5561
# define GFX_TIMSORT_ENABLED_STD_MOVE 0
5662
# endif
57-
#endif // GFX_TIMSORT_DISABLE_STD_MOVE
63+
#endif
5864

5965
#if GFX_TIMSORT_ENABLED_STD_MOVE
6066
#include <utility>

0 commit comments

Comments
 (0)