<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=http://email.email.llvm.org/c/eJylUkFu2zAQfA11WViQKSkyDzo4CQrkAUWPASmuRBY0aZCUjfT1Xco2khboqYAEYTni7MzuqKA_xjcPrH_OxibWvzJ-MDmfE2uPjH-jZwlaBZfrEBeqftHbz0PXeaUmxgVMQSPjL3A16CEbpAOfY3AQUU4G03aGXkOY73AMa7Z-u2QzJBNWp0EhSOUQcoBJOgfsqTnHcLIJ3_PHGYua9hgxr9G_X4LVJJO60181vN2IT5hN0GAT-JBB40w9dGmSizLqRMj35xp-lPIhUgdMnvEh3-R-FfuH0Pxwp9DIiw1rLHRXdG537wSk6Goscdib50kmBIOR7ouaUBrn8cVJv8AsrUub03A622K6jH77oa702GrRClnJlfzEUaOSiXCzW0xIplqjG_9akM1mVTWRUeHc5fHZ0QB_4pSptCmtmMrq-KEbKjMOehaqF41uOzVPT72Q-6GfGiEPQ4vN0FVOKnRppFxQJqr_b2lH3vD9nvO2aRvBu7obZnHgvd5Pou3mXrOuwRMNpi48JWxVHDdKtS6JQGdTTp-gTMkuHvGhMNvstuJzbf0r_GPeW1bv8YISry85oPUifAlatRkZNxe_AdcjDQ4>52847</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            [coroutine] Clang fails to compile when promise type doesn't have return_void
        </td>
    </tr>

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

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

    <tr>
      <th>Reporter</th>
      <td>
          debashish-ghosh
      </td>
    </tr>
</table>

<pre>
    In [this](https://godbolt.org/z/5f744nbbc) code, when the control reaches the end of the coroutine, it should be able to call `promise_type::return_void()`. If the method is not defined, then it is UB. When control doesn't reach the end of coroutine, then the behaviour is well-defined (which is the case here). **Clang fails to compile this**.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJx1ksGOozAMhp8GLlYRJFDKgUNnRivNA6z2OEqIIRmlSZWEVrNPvw5tNd2VVgIhx_Hvz7-RXn2N7w6K7iVpE4vurWAHndI5FvxYsB_0LF5Jb1Plw0LRb3q7uW9bJ-VUsAEmr7Bgr3DV6CBppAOXgrcQUEwa43aGToGf7-ng12TcVmQSRO1Xq0AiCGkRkodJWAvFvj4HfzIRP9LXGTMNPwZMa3AfF28UYVJ3ulXB-034hEl7BSaC8wkUztRD5SYpk1Enyvx8qeBXDh-QymN0BevTDfcZ9i_Q9JhOohYX49eQ5a5o7e7eCYjoqg1pmNvMk4gIGgPVDxVlyc7jqxVugVkYG7dJ_els8tDZ-u1CVaqRq4EPokwmWRxpMd8g3Rv8R2Fz_24YZMOeJiNghCfryjXY8Z8dm6RXWZEaBdZeHp8dSX7ilCg0Ma4Y8_bZoe1LPe7FXhxYN0gumwmlmpBhM_SctxzbQy1KKyTamCcg8NKMrGZNwxiveT2wtmr7eaB61UwDb-dOFW2NJ5qryo3z31aGcWOQ6xIpaU1M8TspYjSLQ3zoi5XWH0aFUkSyU-8W7aMuN-xxY_4DdP_30A">