aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CodeGenFunction.h
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2008-08-30 05:35:15 +0000
committerDaniel Dunbar <daniel@zuster.org>2008-08-30 05:35:15 +0000
commit7f8ea5c5b3a6a4332a841eefdd86b0726722ea7b (patch)
tree48b6d4e8853ec43fafe2c9cf048f42e07d9a1e03 /lib/CodeGen/CodeGenFunction.h
parent19cd87eb5fb3c197e631ce08fd52c446c4d4e8f1 (diff)
Add Objective-C property setter support.
- Change Obj-C runtime message API, drop the ObjCMessageExpr arg in favor of just result type and selector. Necessary so it can be reused in situations where we don't want to cons up an ObjCMessageExpr. - Update aggregate binary assignment to know about special property ref lvalues. - Add CodeGenFunction::EmitCallArg overload which takes an already emitted rvalue. Add CodeGenFunction::StoreComplexIntoAddr. Disabled logic in Sema for parsing Objective-C dot-syntax that accesses methods. This code does not search in the correct order and the AST node has no way of properly representing its results. Updated StmtDumper to print a bit more information about ObjCPropertyRefExprs. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@55561 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CodeGenFunction.h')
-rw-r--r--lib/CodeGen/CodeGenFunction.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/lib/CodeGen/CodeGenFunction.h b/lib/CodeGen/CodeGenFunction.h
index e00c66552f..c8421e609a 100644
--- a/lib/CodeGen/CodeGenFunction.h
+++ b/lib/CodeGen/CodeGenFunction.h
@@ -299,8 +299,22 @@ public:
// Scalar Expression Emission
//===--------------------------------------------------------------------===//
+ /// CallArgList - Type for representing both the value and type of
+ /// arguments in a call.
typedef llvm::SmallVector<std::pair<llvm::Value*, QualType>, 16> CallArgList;
+
+ /// EmitCallArg - Emit the given expression and append the result
+ /// onto the given Args list.
void EmitCallArg(const Expr *E, CallArgList &Args);
+
+ /// EmitCallArg - Append the appropriate call argument for the given
+ /// rvalue and type onto the Args list.
+ void EmitCallArg(RValue RV, QualType Ty, CallArgList &Args);
+
+ /// EmitCall - Generate a call of the given function, expecting the
+ /// given result type, and using the given argument list which
+ /// specifies both the LLVM arguments and the types they were
+ /// derived from.
RValue EmitCall(llvm::Value *Callee,
QualType ResultType,
const CallArgList &Args);
@@ -366,6 +380,10 @@ public:
/// of complex type, storing into the specified Value*.
void EmitComplexExprIntoAddr(const Expr *E, llvm::Value *DestAddr,
bool DestIsVolatile);
+
+ /// StoreComplexToAddr - Store a complex number into the specified address.
+ void StoreComplexToAddr(ComplexPairTy V, llvm::Value *DestAddr,
+ bool DestIsVolatile);
/// LoadComplexFromAddr - Load a complex number from the specified address.
ComplexPairTy LoadComplexFromAddr(llvm::Value *SrcAddr, bool SrcIsVolatile);