diff options
Diffstat (limited to 'lib/Sema/SemaPseudoObject.cpp')
-rw-r--r-- | lib/Sema/SemaPseudoObject.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/Sema/SemaPseudoObject.cpp b/lib/Sema/SemaPseudoObject.cpp index b70c4ca811..3bd671d10c 100644 --- a/lib/Sema/SemaPseudoObject.cpp +++ b/lib/Sema/SemaPseudoObject.cpp @@ -775,12 +775,10 @@ ExprResult Sema::checkPseudoObjectAssignment(Scope *S, SourceLocation opcLoc, VK_RValue, OK_Ordinary, opcLoc); // Filter out non-overload placeholder types in the RHS. - if (const BuiltinType *PTy = RHS->getType()->getAsPlaceholderType()) { - if (PTy->getKind() != BuiltinType::Overload) { - ExprResult result = CheckPlaceholderExpr(RHS); - if (result.isInvalid()) return ExprError(); - RHS = result.take(); - } + if (RHS->getType()->isNonOverloadPlaceholderType()) { + ExprResult result = CheckPlaceholderExpr(RHS); + if (result.isInvalid()) return ExprError(); + RHS = result.take(); } Expr *opaqueRef = LHS->IgnoreParens(); |