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

    <tr>
        <th>Summary</th>
        <td>
            [libc++] `ranges::copy(join_view, out)` isn't constexpr
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            good first issue,
            libc++,
            ranges
      </td>
    </tr>

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

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

<pre>
    ```c++
#include <algorithm>
#include <ranges>
#include <vector>

constexpr auto test(std::vector<std::vector<int>> v, int* out) {
  std::ranges::copy(v | std::views::join, out);
}

static_assert([] {
  int a[4] = {};
  test({{1, 2}, {3, 4}}, a);
  return true;
}());
```

Is rejected by libc++ because the `_CopySegment` helper isn't `constexpr`.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJx0U8uOpDoM_RqziboUHB7FgkU9uqS7vh_QCuCG9KQISkzN1N-PQr0YTY8UEWKf2Mf2iQ7B9CNRDfke8mOiZx6cr6fB2NH8KMsyaVx3raGQt9UC7uOSR5A7QGXG1s4dCVAHbXvnDQ9nUO_f-b0eewr_cF6oZedfzuXbujEw_Zq80DM7wRQYcBu4A7UDtXvcOfxtMSPHWOpdXAAPIh5xJ9zMgJWA8s5fiOfNB7n437rpCri9CCgPL8TF0M874MuZMYa9xQP1aEd5XLMPrNm0HzoE8pH3rcPr7GZkoSHfZ4td3Xzl8RlQPEpe7Ps05sQIwEOEqrhn8Xwz6TUZITzx7EfBfqY_KOI24ta8H8Nds_8vCE9f1DJ1orkKa5r76EVDrZ4DCR5IQCE_Dm66_k_9mUaGQoqB7ERemDAClhwRzzFCITdJV6uuUpVOqE6LqlS4rTBNhpqKAnNKK9K66mhblJRmKpeVzqvPNlNZYmqUqFKZ5lKmOaabIs0apZpcp23Zlp2GTNJZG7ux9nLeON8nJoSZ6qKSW5VY3ZANi84Re-c68Wl8YLFgABHwAIivOp-muzQQ4_vwdQz-1sx9gExaEzi80rFhu7ykVZQ42UJ-I68ooo8oqpWSCvns27NpyextPTBPy3U8AZ56w8PcbFp3BjzF7PftbfIujgzwtFQVAE9L8b8DAAD__4QOHlk">