STL icon indicating copy to clipboard operation
STL copied to clipboard

P3168R2 `std::optional` Range Support

Open StephanTLavavej opened this issue 1 year ago • 5 comments
trafficstars

WG21-P3168R2 std::optional Range Support

Feature-test macro:

#define __cpp_lib_optional_range_support 202406L

Note: We're focused on implementing the remaining library-only features in C++23. Until that's done, we will NOT be accepting PRs for C++26 features.

StephanTLavavej avatar Jun 30 '24 23:06 StephanTLavavej

I know C++26 features aren't being accepted at the moment but this should probably be blocked on the outcome of https://wg21.link/P3415

SuperWig avatar Oct 29 '24 10:10 SuperWig

I know C++26 features aren't being accepted at the moment but this should probably be blocked on the outcome of https://wg21.link/P3415

Half of the reason to ship experimental features is to find problems. If anything I think controversy and/or questions about a feature suggests we should implement it earlier to get feedback.

CaseyCarter avatar Oct 29 '24 18:10 CaseyCarter

I know C++26 features aren't being accepted at the moment but this should probably be blocked on the outcome of https://wg21.link/P3415

P3415 is dead per the GitHub issue.

frederick-vs-ja avatar Mar 29 '25 04:03 frederick-vs-ja

The changes will be trivial if we just let the (const_)iterator types be pointers. Do we want to invent specific iterator types?

frederick-vs-ja avatar Mar 29 '25 05:03 frederick-vs-ja

We conventionally never define iterators to be pointers even though it would be easier, since it allows bogus code to compile.

StephanTLavavej avatar Apr 01 '25 18:04 StephanTLavavej