[clang] [Clang] Add __has_target_builtin macro (PR #126324)
Yaxun Liu via cfe-commits
cfe-commits at lists.llvm.org
Mon Feb 10 09:38:39 PST 2025
================
@@ -357,6 +357,7 @@ void Preprocessor::RegisterBuiltinMacros() {
Ident__has_builtin = RegisterBuiltinMacro("__has_builtin");
Ident__has_constexpr_builtin =
RegisterBuiltinMacro("__has_constexpr_builtin");
+ Ident__has_target_builtin = RegisterBuiltinMacro("__has_target_builtin");
----------------
yxsamliu wrote:
I think we may want to define this macro for offloading languages only. The reason is that non-offloading languages do not need this macro but if they start to use this macro then it will break again in offloading languages like `__has_builtin` did.
https://github.com/llvm/llvm-project/pull/126324
More information about the cfe-commits
mailing list