[all-commits] [llvm/llvm-project] cf09b7: [libc++][ranges] LWG3715: `view_interface::empty` ...
Xiaoyang Liu via All-commits
all-commits at lists.llvm.org
Wed Mar 20 01:48:02 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: cf09b7dec463178fbdefc72dc262d209d865c1c9
https://github.com/llvm/llvm-project/commit/cf09b7dec463178fbdefc72dc262d209d865c1c9
Author: Xiaoyang Liu <siujoeng.lau at gmail.com>
Date: 2024-03-20 (Wed, 20 Mar 2024)
Changed paths:
M libcxx/docs/Status/Cxx23Issues.csv
M libcxx/include/__ranges/view_interface.h
M libcxx/test/std/ranges/range.utility/view.interface/view.interface.pass.cpp
Log Message:
-----------
[libc++][ranges] LWG3715: `view_interface::empty` is overconstrained (#85004)
## Abstract
This pull request implements LWG3715: `view_interface::empty` is
overconstrained. Here is an example similar to those described in the
report, which compiles with `-stdlib=libstdc++` but failed to compile
with `-stdlib=libc++`:
```cpp
// https://godbolt.org/z/EWEoTzah3
std::istringstream input("1 2 3 4 5");
auto i = std::views::istream<int>(input);
auto r = std::views::counted(i.begin(), 4) | std::views::take(2);
assert(!r.empty());
```
## Reference
- [Draft C++ Standard:
[view.interface.general]](https://eel.is/c++draft/view.interface.general)
- [LWG3715](https://wg21.link/LWG3715)
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list