diff options
| author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2011-09-27 17:44:34 +0000 |
|---|---|---|
| committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2011-09-27 17:44:34 +0000 |
| commit | 2b0cf60df39067f689687a7411be1077af0a234d (patch) | |
| tree | 8108af3d105b7818c95b15e0a511bc84754d9993 /clang/include/clang-c | |
| parent | fec95198aa4000ad7bdcb284ac390f1cfbf8d479 (diff) | |
| download | bcm5719-llvm-2b0cf60df39067f689687a7411be1077af0a234d.tar.gz bcm5719-llvm-2b0cf60df39067f689687a7411be1077af0a234d.zip | |
[libclang] Expose array size and element type, patch by Vinay Sajip!
llvm-svn: 140614
Diffstat (limited to 'clang/include/clang-c')
| -rw-r--r-- | clang/include/clang-c/Index.h | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/clang/include/clang-c/Index.h b/clang/include/clang-c/Index.h index fbeb14d3657..f1e62ae4207 100644 --- a/clang/include/clang-c/Index.h +++ b/clang/include/clang-c/Index.h @@ -1965,7 +1965,8 @@ enum CXTypeKind { CXType_ObjCInterface = 108, CXType_ObjCObjectPointer = 109, CXType_FunctionNoProto = 110, - CXType_FunctionProto = 111 + CXType_FunctionProto = 111, + CXType_ConstantArray = 112 }; /** @@ -2057,6 +2058,20 @@ CINDEX_LINKAGE CXType clang_getCursorResultType(CXCursor C); CINDEX_LINKAGE unsigned clang_isPODType(CXType T); /** + * \brief Return the element type of an array type. + * + * If a non-array type is passed in, an invalid type is returned. + */ +CINDEX_LINKAGE CXType clang_getArrayElementType(CXType T); + +/** + * \brief Return the the array size of a constant array. + * + * If a non-array type is passed in, -1 is returned. + */ +CINDEX_LINKAGE long long clang_getArraySize(CXType T); + +/** * \brief Returns 1 if the base class specified by the cursor with kind * CX_CXXBaseSpecifier is virtual. */ |

