summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaDeclCXX.cpp
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2009-08-27 17:24:15 +0000
committerAnders Carlsson <andersca@mac.com>2009-08-27 17:24:15 +0000
commitef4c72135f8ec1ba93beeb0e7d4a6dbcc8ce1fb5 (patch)
treedfcb89ed6a83e80d4db69c4709084ce958f9eb74 /clang/lib/Sema/SemaDeclCXX.cpp
parentf871945c3965d89df3447cf4dd35eee366142b31 (diff)
downloadbcm5719-llvm-ef4c72135f8ec1ba93beeb0e7d4a6dbcc8ce1fb5.tar.gz
bcm5719-llvm-ef4c72135f8ec1ba93beeb0e7d4a6dbcc8ce1fb5.zip
Remove default arguments from TryImplicitConversion and fix a bug found in the process.
llvm-svn: 80258
Diffstat (limited to 'clang/lib/Sema/SemaDeclCXX.cpp')
-rw-r--r--clang/lib/Sema/SemaDeclCXX.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaDeclCXX.cpp b/clang/lib/Sema/SemaDeclCXX.cpp
index c5eda94b6a6..eb4299f79cf 100644
--- a/clang/lib/Sema/SemaDeclCXX.cpp
+++ b/clang/lib/Sema/SemaDeclCXX.cpp
@@ -3144,7 +3144,10 @@ Sema::CheckReferenceInit(Expr *&Init, QualType DeclType,
// the argument expression. Any difference in top-level
// cv-qualification is subsumed by the initialization itself
// and does not constitute a conversion.
- *ICS = TryImplicitConversion(Init, T1, SuppressUserConversions);
+ *ICS = TryImplicitConversion(Init, T1, SuppressUserConversions,
+ /*AllowExplicit=*/false,
+ /*ForceRValue=*/false);
+
// Of course, that's still a reference binding.
if (ICS->ConversionKind == ImplicitConversionSequence::StandardConversion) {
ICS->Standard.ReferenceBinding = true;
OpenPOWER on IntegriCloud