Revert the flags change for now, I have a better idea for this.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@80255 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaExprCXX.cpp b/lib/Sema/SemaExprCXX.cpp
index 1d05008..8592494 100644
--- a/lib/Sema/SemaExprCXX.cpp
+++ b/lib/Sema/SemaExprCXX.cpp
@@ -881,19 +881,14 @@
const char *Flavor, bool AllowExplicit,
bool Elidable)
{
- unsigned Flags = ORF_None;
- if (AllowExplicit)
- Flags |= ORF_AllowExplicit;
-
ImplicitConversionSequence ICS;
ICS.ConversionKind = ImplicitConversionSequence::BadConversion;
if (Elidable && getLangOptions().CPlusPlus0x) {
- Flags |= ORF_ForceRValue;
-
- ICS = TryImplicitConversion(From, ToType, Flags);
+ ICS = TryImplicitConversion(From, ToType, /*SuppressUserConversions*/false,
+ AllowExplicit, /*ForceRValue*/true);
}
if (ICS.ConversionKind == ImplicitConversionSequence::BadConversion) {
- ICS = TryImplicitConversion(From, ToType, Flags);
+ ICS = TryImplicitConversion(From, ToType, false, AllowExplicit);
}
return PerformImplicitConversion(From, ToType, ICS, Flavor);
}