I had code compiling with C++20 using XCode 14.3.
I now updated to XCode 15.4, and that feature is not available anymore...
No member named 'join' in namespace 'std::ranges::views'
Why is join
got dropped?
Define _LIBCPP_ENABLE_EXPERIMENTAL
and you should get it. See <__ranges/join_view.h>
for the explanation:
// Note: `join_view` is still marked experimental because there is an ABI-breaking change that affects `join_view` in
// the pipeline (https://isocpp.org/files/papers/D2770R0.html).
// TODO: make `join_view` non-experimental once D2770 is implemented.
#if _LIBCPP_STD_VER >= 20 && defined(_LIBCPP_ENABLE_EXPERIMENTAL)
Funnily enough, the URL in the header file appears to be incorrect, but P2770R0 https://isocpp.org/files/papers/P2770R0.html correct.