[clang] [Clang][RFC] Bypass TAD during overload resolution if a perfect match exists (PR #133426)

Richard Smith via cfe-commits cfe-commits at lists.llvm.org
Mon Mar 31 14:34:58 PDT 2025


================
@@ -10230,9 +10307,15 @@ Sema::AddArgumentDependentLookupCandidates(DeclarationName Name,
           /*AllowExplicit=*/true, ADLCallKind::UsesADL);
       if (CandidateSet.getRewriteInfo().shouldAddReversed(
               *this, Args, FTD->getTemplatedDecl())) {
+
+        // As template candidates are not deduced immediately,
+        // persist the arry in the overload set.
----------------
zygoloid wrote:

```suggestion
        // persist the array in the overload set.
```

https://github.com/llvm/llvm-project/pull/133426


More information about the cfe-commits mailing list