Home | History | Annotate | Download | only in Sema

Lines Matching refs:Best

1696     // C++ [over.best.ics]p6:
3018 OverloadCandidateSet::iterator Best;
3021 Best, true)) {
3025 CXXConstructorDecl *Constructor = cast<CXXConstructorDecl>(Best->Function);
3031 User.FoundConversionFunction = Best->FoundDecl;
3201 OverloadCandidateSet::iterator Best;
3203 Best, true)) {
3208 = dyn_cast<CXXConstructorDecl>(Best->Function)) {
3220 if (Best->Conversions[0].isEllipsis())
3223 User.Before = Best->Conversions[0].Standard;
3229 User.FoundConversionFunction = Best->FoundDecl;
3236 = dyn_cast<CXXConversionDecl>(Best->Function)) {
3243 User.Before = Best->Conversions[0].Standard;
3246 User.FoundConversionFunction = Best->FoundDecl;
3255 // selecting the best user-defined conversion for a
3258 User.After = Best->FinalConversion;
3354 // C++0x [over.best.ics]p10:
3362 // the best viable function. Otherwise, this conversion is considered worse
3370 // In C++03, we pick #2 as the best viable function.
3371 // In C++11, we pick #1 as the best viable function, because ellipsis
3374 // convert arguments, #2 would be the best viable function in C++11.
3375 // If the best viable function has this conversion, a warning will be issued
4180 OverloadCandidateSet::iterator Best;
4181 switch (CandidateSet.BestViableFunction(S, DeclLoc, Best, true)) {
4193 if (!Best->FinalConversion.DirectBinding)
4197 ICS.UserDefined.Before = Best->Conversions[0].Standard;
4198 ICS.UserDefined.After = Best->FinalConversion;
4200 ICS.UserDefined.ConversionFunction = Best->Function;
4201 ICS.UserDefined.FoundConversionFunction = Best->FoundDecl;
4305 // [over.best.ics]p2).
4314 // conversion functions (13.3.1.6) and choosing the best
4614 // resolution chooses a single best constructor [...] the implicit
5547 OverloadCandidateSet::iterator Best;
5548 switch (CandidateSet.BestViableFunction(*this, Loc, Best)) {
5552 DeclAccessPair::make(Best->Function, Best->FoundDecl.getAccess());
8492 // C++ [over.match.best]p1:
8502 // C++ [over.match.best]p1:
8558 // C++14 [over.match.best]p1 section 2 bullet 3.
8673 /// \brief Computes the best viable function (C++ 13.3.3)
8679 /// \param Best If overload resolution was successful or found a deleted
8680 /// function, \p Best points to the candidate function found.
8685 iterator &Best,
8687 // Find the best viable function.
8688 Best = end();
8691 if (Best == end() || isBetterOverloadCandidate(S, *Cand, *Best, Loc,
8693 Best = Cand;
8697 if (Best == end())
8706 Cand != Best &&
8707 !isBetterOverloadCandidate(S, *Best, *Cand, Loc,
8709 if (S.isEquivalentInternalLinkageDeclaration(Best->Function,
8715 Best = end();
8720 // Best is the best viable function.
8721 if (Best->Function &&
8722 (Best->Function->isDeleted() ||
8723 S.isFunctionConsideredUnavailable(Best->Function)))
8727 S.diagnoseEquivalentInternalLinkageDeclarations(Loc, Best->Function,
10208 // Same algorithm as overload resolution -- one pass to pick the "best",
10209 // another pass to be sure that nothing is better than the best.
10210 auto Best = Matches.begin();
10212 if (isBetterCandidate(I->second, Best->second))
10213 Best = I;
10215 const FunctionDecl *BestFn = Best->second;
10221 // Note: We explicitly leave Matches unmodified if there isn't a clear best
10225 Matches[0] = *Best;
10379 // best viable function in an overload set) that identifies the
10380 // best function template (if it exists).
10870 OverloadCandidateSet::iterator Best;
10871 if (Candidates.BestViableFunction(SemaRef, FnLoc, Best) != OR_Success) {
10909 SemaRef.Diag(Best->Function->getLocation(),
10913 SemaRef.Diag(Best->Function->getLocation(),
10920 SemaRef.Diag(Best->Function->getLocation(),
11088 OverloadCandidateSet::iterator Best;
11090 CandidateSet->BestViableFunction(*this, Fn->getLocStart(), Best) ==
11123 OverloadCandidateSet::iterator *Best,
11133 FunctionDecl *FDecl = (*Best)->Function;
11134 SemaRef.CheckUnresolvedLookupAccess(ULE, (*Best)->FoundDecl);
11137 Fn = SemaRef.FixOverloadedFunctionReference(Fn, (*Best)->FoundDecl, FDecl);
11181 << (*Best)->Function->isDeleted()
11183 << SemaRef.getDeletedOrUnavailableSuffix((*Best)->Function)
11189 FunctionDecl *FDecl = (*Best)->Function;
11190 Fn = SemaRef.FixOverloadedFunctionReference(Fn, (*Best)->FoundDecl, FDecl);
11221 OverloadCandidateSet::iterator Best;
11223 CandidateSet.BestViableFunction(*this, Fn->getLocStart(), Best);
11227 &Best, OverloadResult,
11315 OverloadCandidateSet::iterator Best;
11316 switch (CandidateSet.BestViableFunction(*this, OpLoc, Best)) {
11319 FunctionDecl *FnDecl = Best->Function;
11327 CheckMemberOperatorAccess(OpLoc, Args[0], nullptr, Best->FoundDecl);
11331 Best->FoundDecl, Method);
11349 ExprResult FnExpr = CreateFunctionRefExpr(*this, FnDecl, Best->FoundDecl,
11373 PerformImplicitConversion(Input, Best->BuiltinTypes.ParamTypes[0],
11374 Best->Conversions[0], AA_Passing);
11405 << Best->Function->isDeleted()
11407 << getDeletedOrUnavailableSuffix(Best->Function)
11525 OverloadCandidateSet::iterator Best;
11526 switch (CandidateSet.BestViableFunction(*this, OpLoc, Best)) {
11529 FunctionDecl *FnDecl = Best->Function;
11537 // Best->Access is only meaningful for class members.
11538 CheckMemberOperatorAccess(OpLoc, Args[0], Args[1], Best->FoundDecl);
11550 Best->FoundDecl, Method);
11577 Best->FoundDecl,
11614 PerformImplicitConversion(Args[0], Best->BuiltinTypes.ParamTypes[0],
11615 Best->Conversions[0], AA_Passing);
11621 PerformImplicitConversion(Args[1], Best->BuiltinTypes.ParamTypes[1],
11622 Best->Conversions[1], AA_Passing);
11682 if (isImplicitlyDeleted(Best->Function)) {
11683 CXXMethodDecl *Method = cast<CXXMethodDecl>(Best->Function);
11694 << Best->Function->isDeleted()
11696 << getDeletedOrUnavailableSuffix(Best->Function)
11757 OverloadCandidateSet::iterator Best;
11758 switch (CandidateSet.BestViableFunction(*this, LLoc, Best)) {
11761 FunctionDecl *FnDecl = Best->Function;
11767 CheckMemberOperatorAccess(LLoc, Args[0], Args[1], Best->FoundDecl);
11773 Best->FoundDecl, Method);
11794 Best->FoundDecl,
11821 PerformImplicitConversion(Args[0], Best->BuiltinTypes.ParamTypes[0],
11822 Best->Conversions[0], AA_Passing);
11828 PerformImplicitConversion(Args[1], Best->BuiltinTypes.ParamTypes[1],
11829 Best->Conversions[1], AA_Passing);
11863 << Best->Function->isDeleted() << "[]"
11864 << getDeletedOrUnavailableSuffix(Best->Function)
12016 OverloadCandidateSet::iterator Best;
12018 Best)) {
12020 Method = cast<CXXMethodDecl>(Best->Function);
12021 FoundDecl = Best->FoundDecl;
12022 CheckUnresolvedMemberAccess(UnresExpr, Best->FoundDecl);
12023 if (DiagnoseUseOfDecl(Best->FoundDecl, UnresExpr->getNameLoc()))
12053 << Best->Function->isDeleted()
12055 << getDeletedOrUnavailableSuffix(Best->Function)
12259 OverloadCandidateSet::iterator Best;
12261 Best)) {
12289 << Best->Function->isDeleted()
12291 << getDeletedOrUnavailableSuffix(Best->Function)
12297 if (Best == CandidateSet.end())
12302 if (Best->Function == nullptr) {
12307 Best->Conversions[0].UserDefined.ConversionFunction);
12310 Best->FoundDecl);
12311 if (DiagnoseUseOfDecl(Best->FoundDecl, LParenLoc))
12313 assert(Conv == Best->FoundDecl.getDecl() &&
12321 ExprResult Call = BuildCXXMemberCallExpr(Object.get(), Best->FoundDecl,
12333 CheckMemberOperatorAccess(LParenLoc, Object.get(), nullptr, Best->FoundDecl);
12338 CXXMethodDecl *Method = cast<CXXMethodDecl>(Best->Function);
12352 ExprResult NewFn = CreateFunctionRefExpr(*this, Method, Best->FoundDecl,
12390 Best->FoundDecl, Method);
12466 // the operator is selected as the best match function by the
12490 OverloadCandidateSet::iterator Best;
12491 switch (CandidateSet.BestViableFunction(*this, OpLoc, Best)) {
12525 << Best->Function->isDeleted()
12527 << getDeletedOrUnavailableSuffix(Best->Function)
12533 CheckMemberOperatorAccess(OpLoc, Base, nullptr, Best->FoundDecl);
12536 CXXMethodDecl *Method = cast<CXXMethodDecl>(Best->Function);
12539 Best->FoundDecl, Method);
12545 ExprResult FnExpr = CreateFunctionRefExpr(*this, Method, Best->FoundDecl,
12581 OverloadCandidateSet::iterator Best;
12582 switch (CandidateSet.BestViableFunction(*this, UDSuffixLoc, Best)) {
12599 FunctionDecl *FD = Best->Function;
12600 ExprResult Fn = CreateFunctionRefExpr(*this, FD, Best->FoundDecl,
12685 OverloadCandidateSet::iterator Best;
12687 CandidateSet->BestViableFunction(*this, Fn->getLocStart(), Best);
12694 Loc, nullptr, CandidateSet, &Best,