atomic-1.cc 400 B

123456789101112
  1. // Test that char8_t related atomic types and macros are not present when
  2. // -fchar8_t is not enabled.
  3. // { dg-do compile { target c++11 } }
  4. // { dg-options "-fno-char8_t" }
  5. #include <atomic>
  6. #if defined(ATOMIC_CHAR8_T_LOCK_FREE)
  7. #error ATOMIC_CHAR8_T_LOCK_FREE is defined!
  8. #endif
  9. std::atomic_char8_t x1; // { dg-error "error: .atomic_char8_t. in namespace .std. does not name a type" "char8_t" }