template <class I1, class I2, Sentinel<I2> S1, Sentinel<I1> S2>
bool operator==(
const common_iterator<I1, S1>& x, const common_iterator<I2, S2>& y);
Effects: Equivalent to:
return x.is_sentinel ? (y.is_sentinel || y.iter == x.sentinel) : (!y.is_sentinel || x.iter == y.sentinel);
template <class I1, class I2, Sentinel<I2> S1, Sentinel<I1> S2>
requires EqualityComparableWith<I1, I2>
bool operator==(
const common_iterator<I1, S1>& x, const common_iterator<I2, S2>& y);
Effects: Equivalent to:
return x.is_sentinel ? (y.is_sentinel || y.iter == x.sentinel) : (y.is_sentinel ? x.iter == y.sentinel : x.iter == y.iter);
template <class I1, class I2, Sentinel<I2> S1, Sentinel<I1> S2>
bool operator!=(
const common_iterator<I1, S1>& x, const common_iterator<I2, S2>& y);
Effects: Equivalent to: return !(x == y);
template <class I2, SizedSentinel<I2> I1, SizedSentinel<I2> S1, SizedSentinel<I1> S2>
difference_type_t<I2> operator-(
const common_iterator<I1, S1>& x, const common_iterator<I2, S2>& y);
Effects: Equivalent to:
return x.is_sentinel ? (y.is_sentinel ? 0 : x.sentinel - y.iter) : (y.is_sentinel ? x.iter - y.sentinel : x.iter - y.iter);