llvm-project/clang/test/Lexer/has_feature_realtime_sanitizer.cpp
Chris Apple fb1494137e
[clang][rtsan] Add realtime_sanitizer to Features.def (#106650)
Allows us to introduce the scoped disabler in #106736
2024-09-06 10:46:47 -07:00

13 lines
373 B
C++

// RUN: %clang_cc1 -E -fsanitize=realtime %s -o - | FileCheck --check-prefix=CHECK-RTSAN %s
// RUN: %clang_cc1 -E %s -o - | FileCheck --check-prefix=CHECK-NO-RTSAN %s
#if __has_feature(realtime_sanitizer)
int RealtimeSanitizerEnabled();
#else
int RealtimeSanitizerDisabled();
#endif
// CHECK-RTSAN: RealtimeSanitizerEnabled
// CHECK-NO-RTSAN: RealtimeSanitizerDisabled