This page is a snapshot from the LWG issues list, see the Library Active Issues List for more information and the meaning of New status.
cache_latest_view
should be freestandingSection: 17.3.2 [version.syn], 25.2 [ranges.syn] Status: New Submitter: Hewill Kang Opened: 2024-12-23 Last modified: 2025-01-18
Priority: Not Prioritized
View other active issues in [version.syn].
View all other issues in [version.syn].
View all issues with New status.
Discussion:
cache_latest_view
can be freestanding, but this never comes up in the discussion, which seems to be an oversight.
Proposed resolution:
This wording is relative to N5001.
Modify 17.3.2 [version.syn] as indicated:
#define __cpp_lib_ranges_cache_latest 202411L // freestanding, also in <ranges>
Modify 25.2 [ranges.syn] as indicated:
#include <compare> // see 17.11.1 [compare.syn] #include <initializer_list> // see 17.10.2 [initializer.list.syn] #include <iterator> // see 24.2 [iterator.synopsis] namespace std::ranges { […] // 25.7.34 [range.cache.latest], cache latest view template<input_range V> requires view<V> class cache_latest_view; // freestanding namespace views { inline constexpr unspecified cache_latest = unspecified; } // freestanding […] }