diff options
author | Anders Carlsson <andersca@mac.com> | 2009-04-17 00:06:03 +0000 |
---|---|---|
committer | Anders Carlsson <andersca@mac.com> | 2009-04-17 00:06:03 +0000 |
commit | b14095aa98c6fedd3625920c4ce834bcaf24d9f7 (patch) | |
tree | ff9e31b69547be398d8ccd80b87c8344ccc9386e /lib/CodeGen/CodeGenFunction.h | |
parent | 025452fa0eda63e150cfaeebe64f0a19c96b3a06 (diff) |
Implement basic code generation of constructor calls. We can now compile:
struct S {
S(int, int);
};
void f() {
S s(10, 10);
}
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69330 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CodeGenFunction.h')
-rw-r--r-- | lib/CodeGen/CodeGenFunction.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/CodeGen/CodeGenFunction.h b/lib/CodeGen/CodeGenFunction.h index e96b815dd5..d511da3f7f 100644 --- a/lib/CodeGen/CodeGenFunction.h +++ b/lib/CodeGen/CodeGenFunction.h @@ -25,6 +25,7 @@ #include "CGBlocks.h" #include "CGBuilder.h" #include "CGCall.h" +#include "CGCXX.h" #include "CGValue.h" namespace llvm { @@ -458,6 +459,11 @@ public: /// generating code for an C++ member function. llvm::Value *LoadCXXThis(); + void EmitCXXConstructorCall(const CXXConstructorDecl *D, CXXCtorType Type, + llvm::Value *This, + CallExpr::const_arg_iterator ArgBeg, + CallExpr::const_arg_iterator ArgEnd); + //===--------------------------------------------------------------------===// // Declaration Emission //===--------------------------------------------------------------------===// @@ -632,6 +638,7 @@ public: LValue EmitBlockDeclRefLValue(const BlockDeclRefExpr *E); LValue EmitCXXConditionDeclLValue(const CXXConditionDeclExpr *E); + LValue EmitCXXTemporaryObjectExprLValue(const CXXTemporaryObjectExpr *E); LValue EmitObjCMessageExprLValue(const ObjCMessageExpr *E); LValue EmitObjCIvarRefLValue(const ObjCIvarRefExpr *E); @@ -743,6 +750,9 @@ public: void GenerateStaticCXXBlockVarDeclInit(const VarDecl &D, llvm::GlobalVariable *GV); + void EmitCXXTemporaryObjectExpr(llvm::Value *Dest, + const CXXTemporaryObjectExpr *E); + //===--------------------------------------------------------------------===// // Internal Helpers //===--------------------------------------------------------------------===// |