Skip to content

Commit ef1d310

Browse files
burblebeetkoeppe
authored andcommitted
LWG3880 Clarify operator+= complexity for {chunk,stride}_view::iterator
1 parent 5bbbaf8 commit ef1d310

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

source/ranges.tex

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12504,7 +12504,8 @@
1250412504
Equivalent to:
1250512505
\begin{codeblock}
1250612506
if (x > 0) {
12507-
@\exposid{missing_}@ = ranges::advance(@\exposid{current_}@, @\exposid{n_}@ * x, @\exposid{end_}@);
12507+
ranges::advance(@\exposid{current_}@, @\exposid{n_}@ * (x - 1));
12508+
@\exposid{missing_}@ = ranges::advance(@\exposid{current_}@, @\exposid{n_}@, @\exposid{end_}@);
1250812509
} else if (x < 0) {
1250912510
ranges::advance(@\exposid{current_}@, @\exposid{n_}@ * x + @\exposid{missing_}@);
1251012511
@\exposid{missing_}@ = 0;
@@ -14067,7 +14068,8 @@
1406714068
Equivalent to:
1406814069
\begin{codeblock}
1406914070
if (n > 0) {
14070-
@\exposid{missing_}@ = ranges::advance(@\exposid{current_}@, @\exposid{stride_}@ * n, @\exposid{end_}@);
14071+
ranges::advance(@\exposid{current_}@, @\exposid{stride_}@ * (n - 1));
14072+
@\exposid{missing_}@ = ranges::advance(@\exposid{current_}@, @\exposid{stride_}@, @\exposid{end_}@);
1407114073
} else if (n < 0) {
1407214074
ranges::advance(@\exposid{current_}@, @\exposid{stride_}@ * n + @\exposid{missing_}@);
1407314075
@\exposid{missing_}@ = 0;

0 commit comments

Comments
 (0)