Name += '\0';
return UniqueMangledName(Name.begin(), Name.end());
}
-
}
RValue CodeGenFunction::EmitCallArg(const Expr *E, QualType ArgType) {
+ if (ArgType->isReferenceType())
+ return EmitReferenceBindingToExpr(E, ArgType);
+
return EmitAnyExprToTemp(E);
}
return EmitAnyExpr(E, AggLoc, isAggLocVolatile);
}
+RValue CodeGenFunction::EmitReferenceBindingToExpr(const Expr* E,
+ QualType DestType) {
+ CGM.ErrorUnsupported(E, "reference binding");
+ return GetUndefRValue(DestType);
+}
+
+
/// getAccessedFieldNo - Given an encoded value and a result number, return
/// the input field number being accessed.
unsigned CodeGenFunction::getAccessedFieldNo(unsigned Idx,
void EmitObjCSuperPropertySet(const Expr *E, const Selector &S, RValue Src);
+ /// EmitReferenceBindingToExpr - Emits a reference binding to the passed in
+ /// expression. Will emit a temporary variable if E is not an LValue.
+ RValue EmitReferenceBindingToExpr(const Expr* E, QualType DestType);
+
//===--------------------------------------------------------------------===//
// Expression Emission
//===--------------------------------------------------------------------===//