================
@@ -8852,9 +8852,13 @@ static void AddTemplateConversionCandidateImmediately(
return;
}
+ assert(Specialization && "Missing function template specialization?");
+ // Reject invalid template specialization.
+ if (!AllowRValues &&
+ !Specialization->getConversionType()->isLValueReferenceType())
+ return;
----------------
zyn0217 wrote:
This looks very weird to me, we simply ignore a specialization without a
failure reason and I'm concerned if this would affect diagnostics.
Probably we still need these candidates and rule out them when we perform
overload resolution?
https://github.com/llvm/llvm-project/pull/237738
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits