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

    <tr>
        <th>Summary</th>
        <td>
            Support expanding builtin packs in more context
        </td>
    </tr>

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

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

    <tr>
      <th>Reporter</th>
      <td>
          ilya-biryukov
      </td>
    </tr>
</table>

<pre>
    Builtin pack expansions introduced in #106730 can only be expanded in template arguments and bases right now.
This limitation should be lifted by introducing the relevant code paths. For a list of examples see https://github.com/llvm/llvm-project/blob/db63c57c59e67c65f487b2d88cbc9ac89dfdd01b/clang/test/SemaTemplate/dedup-types-builtin.cpp#L109

For the code changes necessary, see how template arguments and bases are handled in #106730.
We might also have the opportunity to reduce the code duplication from expanding template packs in most places in the code, although this would be a stretch outcome.
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJyUk0-PpDYQxT-NuZSmBQY3cOAwm4hTbrtSzv5TDc4aG9nlnuHbR6a7s6McIuWEkErPr97vlUzJLh5xYuIbE79XMtMa4mTdId-UjUf-Ge6VCuaYvmXryHrYpf4J-LlLn2zwCaynGEzWaMB6YLxt6mvf1qClh-DdAQof4-YxQbjtThKCjEve0FMC6Q0omTBBtMtK4MPHhdXvP1abwNnNkiQbPKQ1ZGeKnrM3QgPq-Od16xegFSGiw7v0BDoYhF3Smi4whwgSnE0E4Qb4KbfdYYKECCvRnlj7zvjM-LxYWrO66LAxPjt3f33e9hj-Qk2Mz8oFxfhs1LXVotdixGuvr-LWDb3iZhi00qPUw2huxtRNGdVO-oXxmTAVge-4yR_PDIoQmry_0bFjelOPiC963xlv_2jqkdXvrH4v_sty5056lX7BBB41piTjwfhvj1XCx3-HKyPCKr1x_0JVsv4TYTuzly4FWOUdzxfDvodI2Vs6gAJELKB_eTF5d1Y_6Nxi2J6gTxgvJ6UvpSWwhUSwO6nx_H2JFPvS0RrysgIV5B8vzBISRSS9Qsikw4aXykytGdtRVjg1vRBDL5q6q9apG5urUN2geiVMNyrDVd-Yduw51-qmeGUnXnNRD5w3ou7EeLnhMGAnGmxNI_orsq7GTVp3KcAvIS6VTSnj1IhuvIrKSYUunWfC-RMpLxcTp7MhKi-JdXUpWfolQZYcTt_zGeOXdNSXY3qGE0scnvCTqhzd9L-LebpNjM9Pw_eJ_x0AAP__ghdRdQ">