diff options
Diffstat (limited to 'lib/Sema/SemaExpr.cpp')
-rw-r--r-- | lib/Sema/SemaExpr.cpp | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp index 6acd2a5b03..a27864f673 100644 --- a/lib/Sema/SemaExpr.cpp +++ b/lib/Sema/SemaExpr.cpp @@ -9790,17 +9790,8 @@ ExprResult Sema::CheckPlaceholderExpr(Expr *E, SourceLocation Loc) { // If this is overload, check for a single overload. assert(BT->getKind() == BuiltinType::Overload); - - if (FunctionDecl *Specialization - = ResolveSingleFunctionTemplateSpecialization(E)) { - // The access doesn't really matter in this case. - DeclAccessPair Found = DeclAccessPair::make(Specialization, - Specialization->getAccess()); - E = FixOverloadedFunctionReference(E, Found, Specialization); - if (!E) return ExprError(); - return Owned(E); - } - - Diag(Loc, diag::err_ovl_unresolvable) << E->getSourceRange(); - return ExprError(); + return ResolveAndFixSingleFunctionTemplateSpecialization(E, false, true, + E->getSourceRange(), + QualType(), + diag::err_ovl_unresolvable); } |