From b1d3f7c909843b71a950a66debab300c155636d3 Mon Sep 17 00:00:00 2001 From: Anders Carlsson Date: Mon, 30 Nov 2009 23:41:22 +0000 Subject: Have ASTRecordLayout keep track of the key function, in preparation of fixing a synthetic ctor/dtor bug. llvm-svn: 90168 --- clang/lib/CodeGen/CGVtable.h | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'clang/lib/CodeGen/CGVtable.h') diff --git a/clang/lib/CodeGen/CGVtable.h b/clang/lib/CodeGen/CGVtable.h index ac3cdee63be..5c2b74c9dd8 100644 --- a/clang/lib/CodeGen/CGVtable.h +++ b/clang/lib/CodeGen/CGVtable.h @@ -91,6 +91,11 @@ class CGVtableInfo { void ComputeMethodVtableIndices(const CXXRecordDecl *RD); + /// GenerateClassData - Generate all the class data requires to be generated + /// upon definition of a KeyFunction. This includes the vtable, the + /// rtti data structure and the VTT. + void GenerateClassData(const CXXRecordDecl *RD); + public: CGVtableInfo(CodeGenModule &CGM) : CGM(CGM) { } @@ -111,10 +116,9 @@ public: llvm::Constant *getVtable(const CXXRecordDecl *RD); llvm::Constant *getCtorVtable(const CXXRecordDecl *RD, const CXXRecordDecl *Class, uint64_t Offset); - /// GenerateClassData - Generate all the class data requires to be generated - /// upon definition of a KeyFunction. This includes the vtable, the - /// rtti data structure and the VTT. - void GenerateClassData(const CXXRecordDecl *RD); + + + void MaybeEmitVtable(GlobalDecl GD); }; } -- cgit v1.2.3