From 95f33555a6d51b6537a9ed3968c3d1c2e4991b51 Mon Sep 17 00:00:00 2001 From: Ted Kremenek Date: Thu, 26 Aug 2010 01:42:22 +0000 Subject: Add libclang API hook "clang_getIBOutletCollectionType" to query the collection type for iboutletcollection attributes. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@112139 91177308-0d34-0410-b5e6-96231b3b80d8 --- tools/c-index-test/c-index-test.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'tools/c-index-test/c-index-test.c') diff --git a/tools/c-index-test/c-index-test.c b/tools/c-index-test/c-index-test.c index 330fa545f9..3f702904a3 100644 --- a/tools/c-index-test/c-index-test.c +++ b/tools/c-index-test/c-index-test.c @@ -195,6 +195,14 @@ static void PrintCursor(CXCursor Cursor) { printf(" (unavailable)"); break; } + + if (Cursor.kind == CXCursor_IBOutletCollectionAttr) { + CXType T = + clang_getCanonicalType(clang_getIBOutletCollectionType(Cursor)); + CXString S = clang_getTypeKindSpelling(T.kind); + printf(" [IBOutletCollection=%s]", clang_getCString(S)); + clang_disposeString(S); + } } } -- cgit v1.2.3-18-g5258