================
@@ -15221,6 +15221,32 @@ ExprResult Sema::BuildCXXMemberCallExpr(Expr *E,
NamedDecl *FoundDecl,
return CheckForImmediateInvocation(CE, CE->getDirectCallee());
}
+void Sema::LookupOverloadedUnaryOp(OverloadCandidateSet &CandidateSet,
+ OverloadedOperatorKind Op,
+ const UnresolvedSetImpl &Fns,
+ ArrayRef<Expr *> Args, bool PerformADL) {
+ assert(Op != OO_None && "Invalid opcode for overloaded unary operator");
+
+ SourceLocation OpLoc = CandidateSet.getLocation();
+ DeclarationName OpName = Context.DeclarationNames.getCXXOperatorName(Op);
+
+ // Add the candidates from the given function set.
+ AddNonMemberOperatorCandidates(Fns, Args, CandidateSet);
+
+ // Add operator candidates that are member functions.
+ AddMemberOperatorCandidates(Op, OpLoc, Args, CandidateSet);
+
+ // Add candidates from ADL.
+ if (PerformADL) {
+ AddArgumentDependentLookupCandidates(OpName, OpLoc, Args,
+ /*ExplicitTemplateArgs*/ nullptr,
+ CandidateSet);
+ }
----------------
cor3ntin wrote:
Let's drop the braces
https://github.com/llvm/llvm-project/pull/210567
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits