e5ccd66801and5029dce492added deprecation warnings to the <stdbool.h> and <stdnoreturn.h> headers, respectively, because the headers are deprecated in C2x. However, there are system headers that include these headers unconditionally, and #warning diagnostics within system headers are shown to users instead of suppressed, which means these deprecation warnings are being triggered in circumstances that users have no control over except to disable all the warnings through the _CLANG_DISABLE_CRT_DEPRECATION_WARNINGS macro or other means. This removes the problematic #warning uses until we find a more palatable solution.
13 lines
418 B
C
13 lines
418 B
C
// RUN: %clang_cc1 -fgnuc-version=4.2.1 -std=c11 -E -dM %s 2>&1 | FileCheck --check-prefix=CHECK-C11 %s
|
|
// RUN: %clang_cc1 -fgnuc-version=4.2.1 -std=c2x -E -dM %s 2>&1 | FileCheck --check-prefix=CHECK-C2X %s
|
|
|
|
#include <stdbool.h>
|
|
|
|
// CHECK-C11: #define bool _Bool
|
|
// CHECK-C11: #define false 0
|
|
// CHECK-C11: #define true 1
|
|
|
|
// CHECK-C2X-NOT: #define bool
|
|
// CHECK-C2X-NOT: #define true
|
|
// CHECK-C2X-NOT: #define false
|