diff --git a/source/algorithms.tex b/source/algorithms.tex index 58377c00dd..ba496d9efd 100644 --- a/source/algorithms.tex +++ b/source/algorithms.tex @@ -4292,9 +4292,8 @@ and \tcode{last1 - first1 != last2 - first2} for the overloads in namespace \tcode{std}; \item - the types of \tcode{first1}, \tcode{last1}, \tcode{first2}, and \tcode{last2} - pairwise model \libconcept{sized_sentinel_for}\iref{iterator.concept.sizedsentinel} - and \tcode{last1 - first1 != last2 - first2} + \tcode{S1} models \tcode{\libconcept{sized_sentinel_for}}, \tcode{S2} models \tcode{\libconcept{sized_sentinel_for}}, + and \tcode{last1 - first1 != last2 - first2} for the first overload in namespace \tcode{ranges}, \item \tcode{R1} and \tcode{R2} each model \libconcept{sized_range} and @@ -4408,8 +4407,8 @@ \item for the first overload, \begin{itemize} -\item \tcode{S1} and \tcode{I1} model \tcode{\libconcept{sized_sentinel_for}}, -\item \tcode{S2} and \tcode{I2} model \tcode{\libconcept{sized_sentinel_for}}, and +\item \tcode{S1} models \tcode{\libconcept{sized_sentinel_for}}, +\item \tcode{S2} models \tcode{\libconcept{sized_sentinel_for}}, and \item \tcode{last1 - first1 != last2 - first2}; \end{itemize} \item diff --git a/source/iterators.tex b/source/iterators.tex index c59e2264c3..a06d20e812 100644 --- a/source/iterators.tex +++ b/source/iterators.tex @@ -1418,13 +1418,13 @@ \pnum A type \tcode{I} other than \cv{}~\tcode{bool} is \defn{integer-like} -if it models \tcode{\libconcept{integral}} or +if it models \libconcept{integral} or if it is an integer-class type. An integer-like type \tcode{I} is \defn{signed-integer-like} -if it models \tcode{\libconcept{signed_integral}} or +if it models \libconcept{signed_integral} or if it is a signed-integer-class type. An integer-like type \tcode{I} is \defn{unsigned-integer-like} -if it models \tcode{\libconcept{unsigned_integral}} or +if it models \libconcept{unsigned_integral} or if it is an unsigned-integer-class type. \pnum @@ -1544,7 +1544,7 @@ \pnum Let \tcode{i} be an object of type \tcode{I}. When \tcode{i} is in the domain of both pre- and post-increment, \tcode{i} is said to be \defn{incrementable}. -\tcode{I} models \tcode{\libconcept{weakly_incrementable}} only if +\tcode{I} models \libconcept{weakly_incrementable} only if \begin{itemize} \item The expressions \tcode{++i} and \tcode{i++} have the same domain. \item If \tcode{i} is incrementable, then both \tcode{++i} @@ -1654,7 +1654,7 @@ \pnum Let \tcode{s} and \tcode{i} be values of type \tcode{S} and \tcode{I} such that \range{i}{s} denotes a range. Types -\tcode{S} and \tcode{I} model \tcode{\libconcept{sentinel_for}} only if +\tcode{S} models \tcode{\libconcept{sentinel_for}} only if \begin{itemize} \item \tcode{i == s} is well-defined. @@ -1699,7 +1699,7 @@ a sentinel of type \tcode{S} such that \range{i}{s} denotes a range. Let $N$ be the smallest number of applications of \tcode{++i} necessary to make \tcode{bool(i == s)} be \tcode{true}. -\tcode{S} and \tcode{I} model \tcode{\libconcept{sized_sentinel_for}} only if +\tcode{S} models \tcode{\libconcept{sized_sentinel_for}} only if \begin{itemize} \item If $N$ is representable by \tcode{iter_difference_t}, then \tcode{s - i} is well-defined and equals $N$. @@ -3004,9 +3004,9 @@ \pnum \effects \begin{itemize} -\item If \tcode{I} and \tcode{S} model \tcode{\libconcept{assignable_from}}, +\item If \tcode{I&} models \tcode{\libconcept{assignable_from}}, equivalent to \tcode{i = std::move(bound)}. -\item Otherwise, if \tcode{S} and \tcode{I} model \tcode{\libconcept{sized_sentinel_for}}, +\item Otherwise, if \tcode{S} models \tcode{\libconcept{sized_sentinel_for}}, equivalent to \tcode{ranges::advance(i, bound - i)}. \item Otherwise, while \tcode{bool(i != bound)} is \tcode{true}, increments \tcode{i}. @@ -3026,12 +3026,12 @@ If \tcode{n == 0}, \range{i}{bound} or \range{bound}{i} denotes a range. If \tcode{n < 0}, \range{bound}{i} denotes a range, \tcode{I} models \libconcept{bidirectional_iterator}, and -\tcode{I} and \tcode{S} model \tcode{\libconcept{same_as}}. +\tcode{S} models \tcode{\libconcept{same_as}}. \pnum \effects \begin{itemize} -\item If \tcode{S} and \tcode{I} model \tcode{\libconcept{sized_sentinel_for}}: +\item If \tcode{S} models \tcode{\libconcept{sized_sentinel_for}}: \begin{itemize} \item If \brk{}$|\tcode{n}| \ge |\tcode{bound - i}|$, equivalent to \tcode{ranges::advance(i, bound)}. @@ -5316,8 +5316,7 @@ Class template \tcode{move_sentinel} is a sentinel adaptor useful for denoting ranges together with \tcode{move_iterator}. When an input iterator type \tcode{I} and sentinel type \tcode{S} model \tcode{\libconcept{sentinel_for}}, -\tcode{move_sentinel} and \tcode{move_iterator} model -\tcode{\libconcept{sentinel_for}, move_iterator>} as well. +\tcode{\libconcept{sentinel_for}, move_iterator>} is modeled as well. \pnum \begin{example} diff --git a/source/ranges.tex b/source/ranges.tex index 415826deeb..352f320f42 100644 --- a/source/ranges.tex +++ b/source/ranges.tex @@ -743,10 +743,8 @@ \pnum \begin{note} -Whenever \tcode{ranges::end(E)} is a valid expression, -the types \tcode{S} and \tcode{I} of -\tcode{ranges::end(E)} and \tcode{ranges::begin(E)} -model \tcode{\libconcept{sentinel_for}}. +Whenever \tcode{ranges::end(E)} is a valid expression, its type models +\tcode{\libconcept{sentinel_for}}. \end{note} \rSec2[range.access.cbegin]{\tcode{ranges::cbegin}} @@ -799,12 +797,10 @@ \pnum \begin{note} -Whenever \tcode{ranges::cend(E)} is a valid expression, -the types \tcode{S} and \tcode{I} of the expressions -\tcode{ranges::cend(E)} and \tcode{ranges::cbegin(E)} -model \tcode{\libconcept{sentinel_for}}. -If \tcode{S} models \libconcept{input_iterator}, -then \tcode{S} also models \exposconceptx{constant-itera\-tor}{constant-iterator}. +Whenever \tcode{ranges::cend(E)} is a valid expression, its type models +\tcode{\libconcept{sentinel_for}}. +If the type of \tcode{ranges::cend(E)} models \libconcept{input_iterator}, +then it also models \exposconcept{constant-iterator}. \end{note} \rSec2[range.access.rbegin]{\tcode{ranges::rbegin}} @@ -897,7 +893,7 @@ \item Otherwise, if \tcode{auto(t.rend())} is a valid expression whose type models - \tcode{\libconcept{sentinel_for}} + \tcode{\libconcept{sentinel_for}}, then \tcode{ranges::rend(E)} is expression-equivalent to \tcode{auto(t.rend())}. @@ -931,10 +927,8 @@ \pnum \begin{note} -Whenever \tcode{ranges::rend(E)} is a valid expression, -the types \tcode{S} and \tcode{I} of the expressions -\tcode{ranges::rend(E)} and \tcode{ranges::rbegin(E)} -model \tcode{\libconcept{sentinel_for}}. +Whenever \tcode{ranges::rend(E)} is a valid expression, its type models +\tcode{\libconcept{sentinel_for}}. \end{note} \rSec2[range.access.crbegin]{\tcode{ranges::crbegin}} @@ -988,12 +982,10 @@ \pnum \begin{note} -Whenever \tcode{ranges::crend(E)} is a valid expression, -the types \tcode{S} and \tcode{I} of the expressions -\tcode{ranges::crend(E)} and \tcode{ranges::crbegin(E)} -model \tcode{\libconcept{sentinel_for}}. -If \tcode{S} models \libconcept{input_iterator}, -then \tcode{S} also models \exposconceptx{constant-itera\-tor}{constant-iterator}. +Whenever \tcode{ranges::crend(E)} is a valid expression, its type models +\tcode{\libconcept{sentinel_for}}. +If the type of \tcode{ranges::crend(E)} models \libconcept{input_iterator}, +then it also models \exposconcept{constant-iterator}. \end{note} \rSec2[range.prim.size]{\tcode{ranges::size}}