From 29e0bccf2bcce22b877f8b2ed173f564c116b97e Mon Sep 17 00:00:00 2001 From: Daniel Dunbar Date: Wed, 24 Sep 2008 04:00:38 +0000 Subject: Refactor some CodeGen functionality: - Add CodeGenFunction::{EmitReturnOfRValue, EmitIvarOffset} - Factor EmitLValueForIvar out of EmitObjCIvarRefLValue. No non-error functionality change (some unsupported errors are degraded to asserts for the time being). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@56543 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/CodeGenFunction.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'lib/CodeGen/CodeGenFunction.h') diff --git a/lib/CodeGen/CodeGenFunction.h b/lib/CodeGen/CodeGenFunction.h index fee9e6f9b3..36130cf6a8 100644 --- a/lib/CodeGen/CodeGenFunction.h +++ b/lib/CodeGen/CodeGenFunction.h @@ -40,6 +40,8 @@ namespace clang { class FunctionDecl; class FunctionTypeProto; class LabelStmt; + class ObjCInterfaceDecl; + class ObjCIvarDecl; class ObjCMethodDecl; class ObjCPropertyImplDecl; class TargetInfo; @@ -334,9 +336,13 @@ public: LValue EmitMemberExpr(const MemberExpr *E); LValue EmitCompoundLiteralLValue(const CompoundLiteralExpr *E); + llvm::Value *EmitIvarOffset(ObjCInterfaceDecl *Interface, + const ObjCIvarDecl *Ivar); LValue EmitLValueForField(llvm::Value* Base, FieldDecl* Field, bool isUnion, unsigned CVRQualifiers); - + LValue EmitLValueForIvar(llvm::Value* Base, const ObjCIvarDecl *Ivar, + unsigned CVRQualifiers); + LValue EmitCXXConditionDeclLValue(const CXXConditionDeclExpr *E); LValue EmitObjCMessageExprLValue(const ObjCMessageExpr *E); @@ -442,6 +448,8 @@ private: /// instructions in IndirectSwitches. void EmitIndirectSwitches(); + void EmitReturnOfRValue(RValue RV, QualType Ty); + /// ExpandTypeFromArgs - Reconstruct a structure of type \arg Ty /// from function arguments into \arg Dst. See ABIArgInfo::Expand. /// -- cgit v1.2.3-18-g5258