mirror of
https://github.com/martinus/unordered_dense.git
synced 2026-01-18 17:21:27 +01:00
Add C++ version check for likely/unlikely attributes
This commit is contained in:
committed by
Martin Leitner-Ankerl
parent
a3a17f01e8
commit
651d9eb217
@@ -143,7 +143,7 @@
|
||||
# pragma intrinsic(_umul128)
|
||||
# endif
|
||||
|
||||
# if __has_cpp_attribute(likely) && __has_cpp_attribute(unlikely)
|
||||
# if __has_cpp_attribute(likely) && __has_cpp_attribute(unlikely) && ANKERL_UNORDERED_DENSE_CPP_VERSION >= 202002L
|
||||
# define ANKERL_UNORDERED_DENSE_LIKELY_ATTR [[likely]] // NOLINT(cppcoreguidelines-macro-usage)
|
||||
# define ANKERL_UNORDERED_DENSE_UNLIKELY_ATTR [[unlikely]] // NOLINT(cppcoreguidelines-macro-usage)
|
||||
# define ANKERL_UNORDERED_DENSE_LIKELY(x) (x) // NOLINT(cppcoreguidelines-macro-usage)
|
||||
|
||||
Reference in New Issue
Block a user