]> granicus.if.org Git - clang/commitdiff
Fixes a typo which caused byte offset in debug info
authorFariborz Jahanian <fjahanian@apple.com>
Mon, 11 Oct 2010 23:55:47 +0000 (23:55 +0000)
committerFariborz Jahanian <fjahanian@apple.com>
Mon, 11 Oct 2010 23:55:47 +0000 (23:55 +0000)
for ivars to be 0. Fixes pr8353.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116273 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/CGDebugInfo.cpp

index f3a3420c5a0f22a726e23951ebe7fc1a466c241d..a07b43a0b5660b9f1f18eb0575bed2856297b807 100644 (file)
@@ -1125,7 +1125,7 @@ llvm::DIType CGDebugInfo::CreateType(const ObjCInterfaceType *Ty,
 
   unsigned FieldNo = 0;
   for (ObjCIvarDecl *Field = ID->all_declared_ivar_begin(); Field;
-       Field = Field->getNextIvar()) {
+       Field = Field->getNextIvar(), ++FieldNo) {
     llvm::DIType FieldTy = getOrCreateType(Field->getType(), Unit);
 
     llvm::StringRef FieldName = Field->getName();