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

    <tr>
        <th>Summary</th>
        <td>
            Nested template with a template template parameter crashes if the template parameter is itself a template parameter
        </td>
    </tr>

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

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

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

<pre>
    I was writing some truly horrific code and clang started crashing (including clangd as used by VSCode \o/). I've reduced it down to this reasonably simple test case which crashes 100% of the time for me.


```
template <typename T>
class C {
  template <bool, template <T> class C> struct FindTypeBase;
  template <template <T> class C> struct FindTypeBase<false, C> {
  };
};

```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyVU8GOozAM_ZpwsQZBKLQcOEzpVprLXna0dyeYklFKqiRM1b9fQzudVruXlaLEjp-fX2xQrrs0b3DGAGdvohkPENyRIPrJXmBw3pveaNCuI8CxA21xhkT0kdjzGIY5R8iNGbWdutlZMB0w5RQYpC7w-1c7E4iydULuhaxTeBNy_UngqZs0g0yEzp1HiA7iYALfY3AjKhYRzPFkWRGFCBoDwXkwerjWpgB5lglZgus5kVGGxffOw5FSke1E9vq0V9ltLW4kZsbIwoo2Xk40Iie_i-LHNczvCAFaEOvt9QLgMUM5Z4Vsn-7mZLjlzWbgPuoIezN271xgy_JF8U-2_2Zpe7R8soAF8yBSrHf3Ik_2cw8SavKqkusqz4sq6Zqiq4sak2iipeYnd5vHcld1NnEA_Pbvxgk9dy2Svw_E3CbxN4LnamIg2z8y3cPJ5G0zxHgKonhdPpP9gatOKtXuyI61n1_Hy8m7D9KRXRPCRIGNcs2PSYYGs5WWJZbVpqiKHHNdK8WLKo2rGhliUZENjSi3otwlppGZlFmd1byXRZVSvtkUKpfrXmGVKxKrjI5obDoXTp0_JL5ZNKjpEDhoTYjhO8hDM4eR6Isfp8h_UeM-hmmMyaK2WaT-AdJdHBY">