Skip to content

Commit f73723c

Browse files
committed
change __item_iteration to support input iterators
1 parent 55acb82 commit f73723c

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

include/exec/sequence/iterate.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,8 @@ namespace exec {
5353
__operation_base<_Iterator, _Sentinel>* __parent_;
5454

5555
void start() & noexcept {
56-
stdexec::set_value(static_cast<_ItemRcvr&&>(__rcvr_), *__parent_->__iterator_++);
56+
stdexec::set_value(static_cast<_ItemRcvr&&>(__rcvr_), *__parent_->__iterator_);
57+
++__parent_->__iterator_;
5758
}
5859
};
5960
};
@@ -125,7 +126,6 @@ namespace exec {
125126
if (this->__iterator_ == this->__sentinel_) {
126127
stdexec::set_value(static_cast<_Receiver&&>(__rcvr_));
127128
} else {
128-
129129
try {
130130
stdexec::start(__op_.emplace(__emplace_from{[&] {
131131
return stdexec::connect(

0 commit comments

Comments
 (0)