================ @@ -4462,6 +4462,9 @@ TemplateDeductionResult Sema::DeduceTemplateArguments( ParamTypesForArgChecking.push_back(ParamType); if (ParamIdx == 0 && HasExplicitObject) { + if (ObjectType.isNull()) + return TemplateDeductionResult::InvalidExplicitArguments; ---------------- mizvekov wrote:
If we already diagnosed it, or if we are in the process of diagnosing it anyway regardless of any details this function will provide, that would be the most sensible return code. Any other return code assumes that it is providing error information that will help diagnose the problem down the line. But we are currently bad at diagnosing deduction failures anyway, and a lot of these deduction error codes are presently ignored, so there are probably no consequences yet. https://github.com/llvm/llvm-project/pull/104328 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits