diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2013-04-18 22:15:49 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2013-04-18 22:15:49 +0000 |
commit | 9adfd8aabbdbe7ce06663c98d3c5e8eda29e6ed1 (patch) | |
tree | bee78fe3be48ff7052fd0f6e308715328b20e160 /clang/include/clang-c | |
parent | 82656cb200b1cf91a95b16a14676ce81bddc890b (diff) | |
download | bcm5719-llvm-9adfd8aabbdbe7ce06663c98d3c5e8eda29e6ed1.tar.gz bcm5719-llvm-9adfd8aabbdbe7ce06663c98d3c5e8eda29e6ed1.zip |
[libclang] Introduce clang_Cursor_getObjCPropertyAttributes to query the written attributes in a property declaration.
rdar://13684512
llvm-svn: 179803
Diffstat (limited to 'clang/include/clang-c')
-rw-r--r-- | clang/include/clang-c/Index.h | 31 |
1 files changed, 30 insertions, 1 deletions
diff --git a/clang/include/clang-c/Index.h b/clang/include/clang-c/Index.h index 3da42ab6b54..fed12f44967 100644 --- a/clang/include/clang-c/Index.h +++ b/clang/include/clang-c/Index.h @@ -32,7 +32,7 @@ * compatible, thus CINDEX_VERSION_MAJOR is expected to remain stable. */ #define CINDEX_VERSION_MAJOR 0 -#define CINDEX_VERSION_MINOR 17 +#define CINDEX_VERSION_MINOR 18 #define CINDEX_VERSION_ENCODE(major, minor) ( \ ((major) * 10000) \ @@ -3360,6 +3360,35 @@ CINDEX_LINKAGE int clang_Cursor_isDynamicCall(CXCursor C); CINDEX_LINKAGE CXType clang_Cursor_getReceiverType(CXCursor C); /** + * \brief Property attributes for a \c CXCursor_ObjCPropertyDecl. + */ +typedef enum { + CXObjCPropertyAttr_noattr = 0x00, + CXObjCPropertyAttr_readonly = 0x01, + CXObjCPropertyAttr_getter = 0x02, + CXObjCPropertyAttr_assign = 0x04, + CXObjCPropertyAttr_readwrite = 0x08, + CXObjCPropertyAttr_retain = 0x10, + CXObjCPropertyAttr_copy = 0x20, + CXObjCPropertyAttr_nonatomic = 0x40, + CXObjCPropertyAttr_setter = 0x80, + CXObjCPropertyAttr_atomic = 0x100, + CXObjCPropertyAttr_weak = 0x200, + CXObjCPropertyAttr_strong = 0x400, + CXObjCPropertyAttr_unsafe_unretained = 0x800 +} CXObjCPropertyAttrKind; + +/** + * \brief Given a cursor that represents a property declaration, return the + * associated property attributes. The bits are formed from + * \c CXObjCPropertyAttrKind. + * + * \param reserved Reserved for future use, pass 0. + */ +CINDEX_LINKAGE unsigned clang_Cursor_getObjCPropertyAttributes(CXCursor C, + unsigned reserved); + +/** * \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. |