update to CXXFunctionalCastExpr to support ir-gen for
type convesions of class objects [class.conv]. WIP.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@80127 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaExprCXX.cpp b/lib/Sema/SemaExprCXX.cpp
index 669705b..cf52bae 100644
--- a/lib/Sema/SemaExprCXX.cpp
+++ b/lib/Sema/SemaExprCXX.cpp
@@ -210,12 +210,15 @@
//
if (NumExprs == 1) {
CastExpr::CastKind Kind = CastExpr::CK_Unknown;
- if (CheckCastTypes(TypeRange, Ty, Exprs[0], Kind, /*functional-style*/true))
+ CXXMethodDecl *ConversionDecl = 0;
+ if (CheckCastTypes(TypeRange, Ty, Exprs[0], Kind, ConversionDecl,
+ /*functional-style*/true))
return ExprError();
exprs.release();
return Owned(new (Context) CXXFunctionalCastExpr(Ty.getNonReferenceType(),
Ty, TyBeginLoc, Kind,
- Exprs[0], RParenLoc));
+ Exprs[0], ConversionDecl,
+ RParenLoc));
}
if (const RecordType *RT = Ty->getAs<RecordType>()) {