Skip to content

Commit a53a988

Browse files
committed
[iterators] Add page breaks, and reflow some code lines.
1 parent f29a90f commit a53a988

File tree

1 file changed

+15
-5
lines changed

1 file changed

+15
-5
lines changed

source/iterators.tex

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -426,6 +426,7 @@
426426
-> decltype(std::begin(c));
427427
template<class C> constexpr auto cend(const C& c) noexcept(noexcept(std::end(c)))
428428
-> decltype(std::end(c));
429+
429430
template<class C> constexpr auto rbegin(C& c) -> decltype(c.rbegin());
430431
template<class C> constexpr auto rbegin(const C& c) -> decltype(c.rbegin());
431432
template<class C> constexpr auto rend(C& c) -> decltype(c.rend());
@@ -442,9 +443,11 @@
442443
template<class C> constexpr auto ssize(const C& c)
443444
-> common_type_t<ptrdiff_t, make_signed_t<decltype(c.size())>>;
444445
template<class T, ptrdiff_t N> constexpr ptrdiff_t ssize(const T (&array)[N]) noexcept;
446+
445447
template<class C> [[nodiscard]] constexpr auto empty(const C& c) -> decltype(c.empty());
446448
template<class T, size_t N> [[nodiscard]] constexpr bool empty(const T (&array)[N]) noexcept;
447449
template<class E> [[nodiscard]] constexpr bool empty(initializer_list<E> il) noexcept;
450+
448451
template<class C> constexpr auto data(C& c) -> decltype(c.data());
449452
template<class C> constexpr auto data(const C& c) -> decltype(c.data());
450453
template<class T, size_t N> constexpr T* data(T (&array)[N]) noexcept;
@@ -1523,6 +1526,8 @@
15231526
@\exposconcept{weakly-equality-comparable-with}@<S, I>; // see \ref{concept.equalitycomparable}
15241527
\end{itemdecl}
15251528

1529+
\newpage
1530+
15261531
\begin{itemdescr}
15271532
\pnum
15281533
Let \tcode{s} and \tcode{i} be values of type \tcode{S} and
@@ -2423,8 +2428,7 @@
24232428
\begin{codeblock}
24242429
template<class In, class Out>
24252430
concept @\deflibconcept{indirectly_movable}@ =
2426-
@\libconcept{indirectly_readable}@<In> &&
2427-
@\libconcept{indirectly_writable}@<Out, iter_rvalue_reference_t<In>>;
2431+
@\libconcept{indirectly_readable}@<In> && @\libconcept{indirectly_writable}@<Out, iter_rvalue_reference_t<In>>;
24282432
\end{codeblock}
24292433

24302434
\pnum
@@ -2542,9 +2546,7 @@
25422546
\begin{codeblock}
25432547
template<class I>
25442548
concept @\deflibconcept{permutable}@ =
2545-
@\libconcept{forward_iterator}@<I> &&
2546-
@\libconcept{indirectly_movable_storable}@<I, I> &&
2547-
@\libconcept{indirectly_swappable}@<I, I>;
2549+
@\libconcept{forward_iterator}@<I> && @\libconcept{indirectly_movable_storable}@<I, I> && @\libconcept{indirectly_swappable}@<I, I>;
25482550
\end{codeblock}
25492551

25502552
\rSec3[alg.req.mergeable]{Concept \cname{mergeable}}
@@ -2910,6 +2912,8 @@
29102912
the ending and starting positions of \tcode{i}.
29112913
\end{itemdescr}
29122914

2915+
\newpage
2916+
29132917
\rSec3[range.iter.op.distance]{\tcode{ranges::distance}}
29142918
\indexlibraryglobal{distance}%
29152919
\begin{itemdecl}
@@ -3477,6 +3481,8 @@
34773481
\tcode{x.base() < y.base()}.
34783482
\end{itemdescr}
34793483

3484+
\newpage
3485+
34803486
\indexlibrarymember{operator<=}{reverse_iterator}%
34813487
\begin{itemdecl}
34823488
template<class Iterator1, class Iterator2>
@@ -4690,8 +4696,10 @@
46904696
void fun(ForwardIterator begin, ForwardIterator end);
46914697

46924698
list<int> s;
4699+
46934700
// populate the list \tcode{s}
46944701
using CI = common_iterator<counted_iterator<list<int>::iterator>, default_sentinel_t>;
4702+
46954703
// call \tcode{fun} on a range of 10 ints
46964704
fun(CI(counted_iterator(s.begin(), 10)), CI(default_sentinel));
46974705
\end{codeblock}
@@ -5108,6 +5116,8 @@
51085116
a range of $N$ elements starting at a given position
51095117
without needing to know the end position a priori.
51105118

5119+
\newpage
5120+
51115121
\pnum
51125122
\begin{example}
51135123
\begin{codeblock}

0 commit comments

Comments
 (0)