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

    <tr>
        <th>Summary</th>
        <td>
            Hardening checks should detect dereferencing std::list<T>::end()
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

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

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

<pre>
    Like `std::map` in https://github.com/llvm/llvm-project/issues/80212#issuecomment-1920171595, dereferencing the end iterator of `std::list` seems to just read off the end of the `std::list` because the end node is embedded but doesn't have a value in it. See https://godbolt.org/z/11Mx8Yhh4

(CC @danakj)
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJykkr1u3DAQhJ9m1Sx8IJf6LVQ45wgpkippUlLavRNtiTyQ1OXn6QOdEwc20qUhiSGXGMw3NiV39iI9VO-geijslucQe7ZXx6P4Ygz8o__ongShVikzmHsw96u9QK3QeZxzvqRdpAFoOLs8b-NhCivQsCzXP9vdJYZHmTLQ4FLaJAENrSJNQOYmTGFdxec73ZHSja66CuiILFFOEsVPzp8xz4LiGV2WaHOIGE6vTC0u5d1VElkT5oCPW8oYxTKG0-llPDwf_zU5ymS3JC9PfWBBl1DWUZiFcdwycpDkgZqMs70KWrzaZZM9C5cP-FnkbSaBx7DkQ4hnoOEn0KD1p-_t13kuQT2Auv-9Uns8IpSKrbdPj0Bdwb3hznS2kF43qm6q1pimmHtiNiKNUg2VWiZbtuPYdrpqasVVZ6fC9aSoVKS0MoZ0c2hU1VA92eqkqOxqDaWS1brlsMPZnRU3Cn2ryJTFYkdZ0q0RRF6-4e0SiPaCxP4GdNzOCUq1J5f-_pJdXqT_YCOL35FNs0xPCdMctoWRJcuU31B9DcEcv4B5_yyIZ6B2D2KLS_9fRTPlrwAAAP__LEPqsQ">