<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/132562>132562</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            [clang][rejects-valid] unfound constrained partial specialization of class template with variadic NTTP of class type
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            clang
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          ericniebler
      </td>
    </tr>
</table>

<pre>
    The following valid C++20 code is rejected by clang trunk:

```c++
struct Integer
{
  int value{};
};

template <Integer... X>
struct Type;

template <Integer... X>
  requires ((X.value == 0) ||...)
struct Type<X...>
{
};
```

result:

```
<source>:11:8: error: class template partial specialization is not more specialized than the primary template [-Winvalid-partial-specialization]
   11 | struct Type<X...>
 |        ^
<source>:7:8: note: template is declared here
    7 | struct Type;
      |        ^
1 error generated.
```

This bug requires the class type to be parameterized on a variadic pack of non-type template parameters of class type.

repro:
https://godbolt.org/z/6W6hbhGGE

</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJyMVE2P2zgM_TXMhYhhS5E9OfiQj6bYy2IPA3SussSxtVUkryRPkf76heyk3jYosIEBE2L4yPeeTBmj6R1RC-II4ryRUxp8aCkY5Qx1lsKm8_rWvg6E795a_824Hj-kNRpPwI7AjqxE5TWhiRjob1KJNHY3VFa6HlOY3FfgByjnpy6XRy2lUB5iCpNK-IdL1FPI_2nyMaJxKfeZKB80Z-DHOfkIykOi62hlIgR-upcXRYFvwD-tuK-3kf5nBWKgfyYTKCKwF2Avb8XcH4GfgZ-xBLZHaE7QnIqiALb_tcvpLZ_PWAuJddoH72WOQHGy6VmVHPNT9FNQlHH4oaqAH16AH5BC8CEHysoY8QeVUYZkpMU4kjLSmu8yGe-yGc4nvPpAa4o0pkE6TAPhGMxVhtsKBOK4_WLcbO32jrr9GRXEedYJqyoLgb9jPyfvPxCfnmk1D1bOJ8rvH1OYiJqUlYE0DhRo6YfNc7_jPYXP3apFLezJUZCJdPHswetgInZTv5qeVbmLexsJk8dulldeKVGY1fMOJX7IYKQ2CkepvqJ_R-fddin5jylLVcz5FbR4-D8Gv9g_pDTGHLILsEvvdedtKnzogV2-A7vUX-qhGz5_zrQ2uuV6z_dyQ23V7Fjd7IRoNkOralbuqBOCRFc17L2rheB7wWWpdoo3emNaVjJRcsZYWQnRFKrRmtX7mst6X3ZSw66kqzS2sPbjmttvTIwTtRVnomYbKzuycd4RjM0fNjCW10Voc8G2m_oIu9KamOIKkUyy82JZKsQZxHHZEHE7XzMQZ5zcu5-cRuVdTEEaR_p3d3qV8qHzN5OG1Y8_X1__-lnvzRRs-4vEJg1TVyh_BXbJo95f2zH4PBqwy0w9Arvc2X-07N8AAAD__1JAmOY">