diff --git a/CMakeLists.txt b/CMakeLists.txt index cab1ff68e0..f60142b207 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -238,7 +238,7 @@ if (NOT MSVC) check_cxx_source_compiles(" #include int main() { - return std::atomic{}; + return static_cast(std::atomic{}); } " protobuf_HAVE_BUILTIN_ATOMICS) if (NOT protobuf_HAVE_BUILTIN_ATOMICS)