diff options
author | Albert Gutowski <agutowski@google.com> | 2016-09-13 19:26:42 +0000 |
---|---|---|
committer | Albert Gutowski <agutowski@google.com> | 2016-09-13 19:26:42 +0000 |
commit | c79ec5a5d7fc97bc97599a858b4023a775d63910 (patch) | |
tree | 4298b790310d8146928d7b89d233ba783f2fab12 /include/clang/Basic/Builtins.h | |
parent | 32a02648ebefcd05452b87f0bb6596afcdd58d46 (diff) |
Add some MS aliases for existing intrinsics
Reviewers: thakis, compnerd, majnemer, rsmith, rnk
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D24330
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@281375 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic/Builtins.h')
-rw-r--r-- | include/clang/Basic/Builtins.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/clang/Basic/Builtins.h b/include/clang/Basic/Builtins.h index 15e9a413fb..c89880de0a 100644 --- a/include/clang/Basic/Builtins.h +++ b/include/clang/Basic/Builtins.h @@ -139,6 +139,13 @@ public: return strchr(getRecord(ID).Attributes, 'f') != nullptr; } + // \brief Returns true if this builtin requires appropriate header in other + // compilers. In Clang it will work even without including it, but we can emit + // a warning about missing header. + bool isHeaderDependentFunction(unsigned ID) const { + return strchr(getRecord(ID).Attributes, 'h') != nullptr; + } + /// \brief Determines whether this builtin is a predefined compiler-rt/libgcc /// function, such as "__clear_cache", where we know the signature a /// priori. |