Skip to content

Commit

Permalink
iter_moveを定義
Browse files Browse the repository at this point in the history
  • Loading branch information
acd1034 committed Sep 18, 2022
1 parent d928721 commit 0a83c35
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions include/ns/enumerate_view.hpp
Expand Up @@ -173,6 +173,13 @@ namespace ns {
std::ranges::random_access_range<View> {
return x.current_ - y.current_;
}

friend constexpr std::pair<std::size_t,
std::ranges::range_rvalue_reference_t<View>>
iter_move(const iterator& x) noexcept(
noexcept(std::ranges::iter_move(x.current_))) {
return {x.count_, std::ranges::iter_move(x.current_)};
}
};

template <std::ranges::input_range View>
Expand Down

0 comments on commit 0a83c35

Please sign in to comment.