Skip to content

Commit 4a44e00

Browse files
committed
[llvm] Define __has_warning in Compiler.h if it isn't defined
Follow-up to #141091.
1 parent 86685b9 commit 4a44e00

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

llvm/include/llvm/Support/Compiler.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,10 @@
3939
# define __has_builtin(x) 0
4040
#endif
4141

42+
#ifndef __has_warning
43+
# define __has_warning(x) 0
44+
#endif
45+
4246
// Only use __has_cpp_attribute in C++ mode. GCC defines __has_cpp_attribute in
4347
// C mode, but the :: in __has_cpp_attribute(scoped::attribute) is invalid.
4448
#ifndef LLVM_HAS_CPP_ATTRIBUTE

0 commit comments

Comments
 (0)