1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-18 03:30:45 +00:00
nixpkgs/pkgs/test/cc-wrapper/atomics.cc
Artturin dabfaef444 tests.cc-wrapper: add atomics test
`-std=c++17` is for clang 5
2023-11-16 00:23:56 +02:00

9 lines
120 B
C++

#include <atomic>
#include <cstdint>
int main()
{
std::atomic_int x = {0};
return !std::atomic_is_lock_free(&x);
}