combine() fails on containers with different size
Open
- Dominant language
- C++
- Stars
- 45
- Forks
- 104
- PR merge metrics
- No merged PRs in 30d
Description
The code
#include \
#include \
#include \
#include \
int main() {
std::vector vec1 = { 1, 2 };
std::vector vec2 = { 5, 6, 7 };
const auto& zip_view = boost::range::combine(vec1, vec2);
std::cout << "boost::range::combine(vec1, vec2).size() = " << std::ranges::size(zip_view) << std::endl;
for (auto const& zipped : zip_view) {
int first, second;
boost::tie(first, second) = zipped;
std::cout << first << " " << second << std::endl;
}
return 0;
}
produces an output
boost::range::combine(vec1, vec2).size() = 2
1 5
2 6
and fails while access over vec1.end()
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.