[clang] [Clang][Sema] fix a bug on template partial specialization (PR #89862)

Erich Keane via cfe-commits cfe-commits at lists.llvm.org
Wed Apr 24 12:18:23 PDT 2024


================
@@ -7706,7 +7706,7 @@ ExprResult Sema::CheckTemplateArgument(NonTypeTemplateParmDecl *Param,
     // FIXME: The language rules don't say what happens in this case.
     // FIXME: We get an opaque dependent type out of decltype(auto) if the
     // expression is merely instantiation-dependent; is this enough?
-    if (CTAK == CTAK_Deduced && Arg->isTypeDependent()) {
+    if (Arg->isTypeDependent()) {
----------------
erichkeane wrote:

I think this makes reasonable sense, I note that this covers the  CTAK==CTAK_Specified case, but I would like a test where it is an array-bound so that we can ensure we're getting that right as well.

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


More information about the cfe-commits mailing list