]> granicus.if.org Git - clang/commitdiff
Make ComputeThisAdjustmentBaseOffset public for now.
authorAnders Carlsson <andersca@mac.com>
Wed, 24 Feb 2010 22:18:01 +0000 (22:18 +0000)
committerAnders Carlsson <andersca@mac.com>
Wed, 24 Feb 2010 22:18:01 +0000 (22:18 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@97066 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/CGVtable.cpp

index 61dd11e4901afe0a5253931ad5e152255a4a434e..f0a95b92da6b7d2a77554cec39938375b0e9ca93 100644 (file)
@@ -144,17 +144,18 @@ private:
                           const CXXMethodDecl *NewMD,
                           SubobjectOffsetsMapTy &Offsets);
   
-  /// ComputeThisAdjustmentBaseOffset - Compute the base offset for adjusting
-  /// the 'this' pointer from the base subobject to the derived subobject.
-  BaseOffset ComputeThisAdjustmentBaseOffset(BaseSubobject Base,
-                                             BaseSubobject Derived);
-                                             
   static void MergeSubobjectOffsets(const SubobjectOffsetsMapTy &NewOffsets,
                                     SubobjectOffsetsMapTy &Offsets);
 
 public:
   explicit FinalOverriders(const CXXRecordDecl *MostDerivedClass);
-  
+
+  /// ComputeThisAdjustmentBaseOffset - Compute the base offset for adjusting
+  /// the 'this' pointer from the base subobject to the derived subobject.
+  /// FIXME: This should move to VtableBuilder.
+  BaseOffset ComputeThisAdjustmentBaseOffset(BaseSubobject Base,
+                                             BaseSubobject Derived) const;
+
   /// getOverrider - Get the final overrider for the given method declaration in
   /// the given base subobject.
   OverriderInfo getOverrider(BaseSubobject Base,
@@ -357,7 +358,7 @@ ComputeReturnAdjustmentBaseOffset(ASTContext &Context,
 
 BaseOffset
 FinalOverriders::ComputeThisAdjustmentBaseOffset(BaseSubobject Base,
-                                                 BaseSubobject Derived) {
+                                                 BaseSubobject Derived) const {
   const CXXRecordDecl *BaseRD = Base.getBase();
   const CXXRecordDecl *DerivedRD = Derived.getBase();