[cfe-commits] r148524 - in /cfe/trunk: test/Index/index-attrs.m tools/libclang/IndexingContext.cpp

Argyrios Kyrtzidis akyrtzi at gmail.com
Thu Jan 19 17:38:51 PST 2012


Author: akirtzidis
Date: Thu Jan 19 19:38:51 2012
New Revision: 148524

URL: http://llvm.org/viewvc/llvm-project?rev=148524&view=rev
Log:
[libclang] Fix crash when indexing attributes, rdar://10702250.

Added:
    cfe/trunk/test/Index/index-attrs.m
Modified:
    cfe/trunk/tools/libclang/IndexingContext.cpp

Added: cfe/trunk/test/Index/index-attrs.m
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/index-attrs.m?rev=148524&view=auto
==============================================================================
--- cfe/trunk/test/Index/index-attrs.m (added)
+++ cfe/trunk/test/Index/index-attrs.m Thu Jan 19 19:38:51 2012
@@ -0,0 +1,7 @@
+ at class Foo;
+ at interface Bar
+ at property (retain) __attribute__((iboutletcollection(Foo))) Foo *prop;
+ at end
+
+// RUN: c-index-test -index-file %s | FileCheck %s
+// CHECK:      <attribute>: attribute(iboutletcollection)= [IBOutletCollection=ObjCInterface]

Modified: cfe/trunk/tools/libclang/IndexingContext.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/libclang/IndexingContext.cpp?rev=148524&r1=148523&r2=148524&view=diff
==============================================================================
--- cfe/trunk/tools/libclang/IndexingContext.cpp (original)
+++ cfe/trunk/tools/libclang/IndexingContext.cpp Thu Jan 19 19:38:51 2012
@@ -49,7 +49,7 @@
 
 IBOutletCollectionInfo::IBOutletCollectionInfo(
                                           const IBOutletCollectionInfo &other)
-  : AttrInfo(CXIdxAttr_IBOutletCollection, other.cursor, other.loc, A) {
+  : AttrInfo(CXIdxAttr_IBOutletCollection, other.cursor, other.loc, other.A) {
 
   IBCollInfo.attrInfo = this;
   IBCollInfo.classCursor = other.IBCollInfo.classCursor;





More information about the cfe-commits mailing list