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

    <tr>
        <th>Summary</th>
        <td>
            Error with modules, format, pipe operator - function with deduced return type cannot be used
        </td>
    </tr>

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

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

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

<pre>
    This seems to be a bug.

https://godbolt.org/z/o1o97ar4j

Something bad happening with C++20 modules + `<format>` causes this confusing error. Remove the `#include <format>` and it goes away.

```console
In module 'MathMod' imported from /app/main.cc:3:
PolyTri.cc:15:37: error: function 'operator|<std::vector<int> &, std::__range_adaptor_closure_t<std::__bind_back_t<std::ranges::views::__drop::__fn, std::tuple<int>>>>' with deduced return type cannot be used before it is defined
        auto wtf = this->dcel.faces | std::views::drop(1); 
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyMU01v4zgM_TX0hWhgS7bTHHxI0hrYwwCL3bkHskTHmrFFQx8tur9-oSRt057GEGxZFMlHvkcVgj07og6aAzRPhUpxYt95Z38rZ8gXA5u37udkAwaiJWBkHAgVDum8gfIJyv31PcW4BpB7ED2I_sxm4Dlu2J9B9P-B6Lni3Vb5-te907-8UJysO-OgDE5qXcnlv1cbJzyCOIA4iBIXNmmmgCAOCG0J8jiyX1QE-QxtiVqlQAFjBqnZjSnkGOQ9-w3-Qwu_EMaJLq5CWqfnZAi_R1HOoI14ZgqoXtXbl-qy62VpdoFnup7-5W7QEMT2h4rTDzYgtmiXlX0kg6PnBUH0al1B9IuybqM1yL3MjbqE-Jvnt5_eXo-rJtu2IPdX9HkzJqejZZdT8EpeRfawPYI8hmhyGLl_IZ0P5dG6XAyCaEEc8cN-OnnlznRSRq2R_UnPHJKnU7wPcjoN1pnToPTvr4aLb7hlsvQa3u8bz-v7fnRfMsa0zvQB6HOJ7ZVaQyZpMugpJu8wvq2EWjnHMYsrBTI40MieMiM2oKHROjLXluHtUSkyvsYRQT5dyH8A-Ww0zZtR6ayW7R2iO-QX3OKxArEDecBvBBemk2Ynd6qgrmofy0ZWUjTF1Km6rXbU1DXVplJUk25rIjWOphqa6lEWthOlkGVdyqquGtFsWtLDTtdju6W6LVUDdUmLsvNmnl-WPBqFDSFR11a7ShSzGmgO73Pou3zpYUjnAHU52xDDp1u0cabuOUvk2s_bgGQObpoWR1ztSvguGXz4VNIfUlAkP3ffxtrGKQ0bzQuIPsO5fR5Wz79IRxD9paQAor9U9X8AAAD__3yDXuA">