Skip to content

Commit

Permalink
Honour ADL.
Browse files Browse the repository at this point in the history
  • Loading branch information
thorstenhater committed Sep 20, 2024
1 parent 28a0cce commit eb4c56e
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions arbor/util/range.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -156,8 +156,9 @@ range<T, T> range_n(T t, size_t n) {

template <typename Seq>
auto canonical_view(Seq&& s) {
auto b = std::begin(s);
auto e = std::end(s);
using std::begin;
auto b = begin(s);
auto e = end(s);
return make_range(make_sentinel_iterator(b, e), make_sentinel_end(b, e));
}

Expand All @@ -166,8 +167,9 @@ auto canonical_view(Seq&& s) {

template <typename Seq>
auto strict_view(Seq&& s) {
auto b = std::begin(s);
auto e = std::end(s);
using std::begin;
auto b = begin(s);
auto e = end(s);
return make_range(b, b==e? b: std::next(util::upto(b, e)));
}

Expand Down

0 comments on commit eb4c56e

Please sign in to comment.