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

    <tr>
        <th>Summary</th>
        <td>
            KwinFT C++20 ranges MR 168 doesn't compile with Clang
        </td>
    </tr>

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

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

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

<pre>
    The KwinFT project came up with https://gitlab.com/kwinft/kwinft/-/merge_requests/168 which makes use of C++20 ranges features. This MR compiles fine with GCC 12.2 but I ran into a compilation issue with Clang 16 (df868edee561eb973edd85ec9df41c67aa0bff6b) - and the KwinFT devs told me that it is a compiler bug, therefore filing this issue.

```
/home/marcus/Downloads/KDE/kwinft-git/src/kwin/win/stacking.h:155:12: error: no matching function for call to 'ensure_stacking_order_in_list'
    return ensure_stacking_order_in_list(*space->stacking_order, list);
           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~

```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy1U0tv2zAM_jXyhYhhy_Hr4EObxzAUuwy9B7JFx1plK5PkBvv3oxyn7dABO82gJYoSxU_kx9bIX83zgPB0VdPxGS7W_MDOQydGhPkCV-UHGLy_OJY9MH4kOSuvRRt3ZqTFC7n1_qOyoX9Ee8aTxZ8zOu_IkBYVXAfVDTCKF3QwOwTTw47xRxKegBXTmew9Cj9bdDE8D8rBt-9AYS5Khy014Q3Ol90OUh5zaGcPX4MrqMkbEOth4ZUhk3Pz6rDTdDukBTBeyb4qKpSIeZFiW5cZSlnl2NWy36ZdUQqRtH1ftIzXsAExSfDv2ZH46sAbLYGy4wfhQZG4t8hoCdOZ8V1wstgbi4RbK4ruw3sWTDFL9ix5WMciWeW25MfBjBhSKGw3h9TtzXXSRsigP-0Pb6neUB1o4Wy3mmi6jc6L7oVixgPVLM3zMHIaAK01NiiToTr4bgjA-nnqloQRWiq71vRASlSJk6NKnO6XnYyVaE9qOmnlKHB5Awz0WaSaTfAPh4rxB3cRHW5YdvjzUEjY7VDNssf3i9eP5QdW_gf5WxkibNKi4CWvky2PZJPJOqtF5Inz2Kws-MRaomkguDToKP-lv7PhA_ui2ermUx8N872PtH69T5u1B2m58CUUPi-LPImGps3Toq7ltkXZ1VW7zUnDJKO2wazKKhlRZ6J2DcsJIZ_weqMc6SzfR6rhCedJndRpltL74qSqMUvzdltSH2SiZdsER6F0HHDExp4j2yyQiNWONkOR3PumcE6dJ8QlHN0vZj8Y24wuLatoCdwswH8DmR9dMA">