stdbool.cpp 633 B

12345678910111213141516171819
  1. // RUN: %clang_cc1 -E -dM %s | FileCheck --check-prefix=CHECK-GNU-COMPAT %s
  2. // RUN: %clang_cc1 -std=c++98 -E -dM %s | FileCheck --check-prefix=CHECK-CONFORMING %s
  3. // RUN: %clang_cc1 -fsyntax-only -std=gnu++98 -verify -Weverything %s
  4. #include <stdbool.h>
  5. #define zzz
  6. // CHECK-GNU-COMPAT: #define _Bool bool
  7. // CHECK-GNU-COMPAT: #define bool bool
  8. // CHECK-GNU-COMPAT: #define false false
  9. // CHECK-GNU-COMPAT: #define true true
  10. // CHECK-CONFORMING-NOT: #define _Bool
  11. // CHECK-CONFORMING: #define __CHAR_BIT__
  12. // CHECK-CONFORMING-NOT: #define false false
  13. // CHECK-CONFORMING: #define zzz
  14. zzz
  15. // expected-no-diagnostics
  16. extern bool x;