Description: Fix CheckCxxAtomic to detect more accurately Some platforms like riscv64 does not have full support for atomic primitives, yet passes the test. Adding operator++ fixes this issue. Author: Eric Long Last-Update: 2022-08-30 --- a/cmake/modules/CheckCxxAtomic.cmake +++ b/cmake/modules/CheckCxxAtomic.cmake @@ -32,7 +32,7 @@ std::atomic w2; std::atomic w4; std::atomic w8; - return w1 + w2 + w4 + w8; + return ++w1 + ++w2 + ++w4 + ++w8; } " ${var}) endfunction(check_cxx_atomics)