GCC has a very toxic view on friendship as a concept tbh

This commit is contained in:
Andrew Cassidy 2022-06-08 23:12:42 -07:00
parent a33cb8ea67
commit 527067839f

View File

@ -159,6 +159,8 @@ template <typename T> class const_iterator : public index_iterator_base<const_it
typedef long long difference_type;
typedef T value_type;
friend base;
const_iterator() : base(0), _value(T{}) {}
const_iterator(T value, size_t index = 0) : base(index), _value(value) {}
@ -184,6 +186,8 @@ class index_iterator : public index_iterator_base<index_iterator<R>> {
typedef long long difference_type;
typedef range_value_t<R> value_type;
friend base;
index_iterator() : base(0), _range(nullptr) {}
index_iterator(R &range, size_t index) : base(index), _range(&range) {}