diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2012-07-02 23:54:36 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2012-07-02 23:54:36 +0000 |
commit | f39a7aea7dd0bf0716a066e2db2f97ea8730e4fa (patch) | |
tree | fdcd2af9e8a3dc278eaecda2c16d22e2ef468185 /include/clang-c | |
parent | 6c89eafc90f5c51a0bf185a993961170aee530c2 (diff) |
[libclang] Introduce clang_Cursor_isDynamicCall which,
given a cursor pointing to a C++ method call or an ObjC message,
returns non-zero if the method/message is "dynamic", meaning:
For a C++ method: the call is virtual.
For an ObjC message: the receiver is an object instance, not 'super' or a
specific class.
rdar://11779185
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@159627 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang-c')
-rw-r--r-- | include/clang-c/Index.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/clang-c/Index.h b/include/clang-c/Index.h index b34918fb6f..33a92e4653 100644 --- a/include/clang-c/Index.h +++ b/include/clang-c/Index.h @@ -3144,6 +3144,19 @@ CINDEX_LINKAGE CXCursor clang_getCanonicalCursor(CXCursor); CINDEX_LINKAGE int clang_Cursor_getObjCSelectorIndex(CXCursor); /** + * \brief Given a cursor pointing to a C++ method call or an ObjC message, + * returns non-zero if the method/message is "dynamic", meaning: + * + * For a C++ method: the call is virtual. + * For an ObjC message: the receiver is an object instance, not 'super' or a + * specific class. + * + * If the method/message is "static" or the cursor does not point to a + * method/message, it will return zero. + */ +CINDEX_LINKAGE int clang_Cursor_isDynamicCall(CXCursor C); + +/** * \brief Given a cursor that represents a declaration, return the associated * comment's source range. The range may include multiple consecutive comments * with whitespace in between. |