]> granicus.if.org Git - clang/commitdiff
We don't want to confuse this layout with the BLayout from the builder.
authorMike Stump <mrs@apple.com>
Wed, 19 Aug 2009 14:06:50 +0000 (14:06 +0000)
committerMike Stump <mrs@apple.com>
Wed, 19 Aug 2009 14:06:50 +0000 (14:06 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@79422 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/CGCXX.cpp

index 6c054ea5fcab74fc011fc27685cc14e0a5c258c0..7b02c3a781547a9ba685def65a923dbb511687a1 100644 (file)
@@ -853,20 +853,20 @@ public:
   void GenerateVBaseOffsets(std::vector<llvm::Constant *> &offsets,
                             const CXXRecordDecl *RD,
                            llvm::SmallSet<const CXXRecordDecl *, 32> &SeenVBase,
-                            uint64_t Offset, const ASTRecordLayout &BLayout) {
+                            uint64_t Offset, const ASTRecordLayout &Layout) {
     for (CXXRecordDecl::base_class_const_iterator i =RD->bases_begin(),
            e = RD->bases_end(); i != e; ++i) {
       const CXXRecordDecl *Base = 
         cast<CXXRecordDecl>(i->getType()->getAs<RecordType>()->getDecl());
       if (i->isVirtual() && !SeenVBase.count(Base)) {
         SeenVBase.insert(Base);
-        int64_t BaseOffset = Offset/8 + BLayout.getVBaseClassOffset(Base) / 8;
+        int64_t BaseOffset = Offset/8 + Layout.getVBaseClassOffset(Base) / 8;
         llvm::Constant *m;
         m = llvm::ConstantInt::get(llvm::Type::getInt64Ty(VMContext), BaseOffset);
         m = llvm::ConstantExpr::getIntToPtr(m, Ptr8Ty);
         offsets.push_back(m);
       }
-      GenerateVBaseOffsets(offsets, Base, SeenVBase, Offset, BLayout);
+      GenerateVBaseOffsets(offsets, Base, SeenVBase, Offset, Layout);
     }
   }
 };