@@ -36,7 +36,7 @@ <h1>Effect of execution policies on algorithm execution</h1>
36
36
< cxx-example > < pre > using namespace std::experimental::parallel;
37
37
int a[] = {0,1};
38
38
std::vector<int> v;
39
- for_each(par, std::begin(a), std::end(a), [&](int i) {
39
+ for_each(par, std::begin(a), std::end(a), [& ](int i) {
40
40
v.push_back(i*2+1);
41
41
});
42
42
foo bar</ pre >
@@ -66,7 +66,7 @@ <h1>Effect of execution policies on algorithm execution</h1>
66
66
int x;
67
67
std::mutex m;
68
68
int a[] = {1,2};
69
- for_each(par, std::begin(a), std::end(a), [&](int) {
69
+ for_each(par, std::begin(a), std::end(a), [& ](int) {
70
70
m.lock();
71
71
++x;
72
72
m.unlock();
@@ -92,7 +92,7 @@ <h1>Effect of execution policies on algorithm execution</h1>
92
92
int x;
93
93
std::mutex m;
94
94
int a[] = {1,2};
95
- for_each(vec, std::begin(a), std::end(a), [&](int) {
95
+ for_each(vec, std::begin(a), std::end(a), [& ](int) {
96
96
m.lock();
97
97
++x;
98
98
m.unlock();
@@ -152,7 +152,7 @@ <h1><code>ExecutionPolicy</code> algorithm overloads</h1>
152
152
Parallel algorithms coexist alongside their sequential counterparts as overloads
153
153
distinguished by a formal template parameter named < code > ExecutionPolicy</ code > . This
154
154
template parameter corresponds to the parallel algorithm's first function parameter, whose
155
- type is < code > ExecutionPolicy&& </ code > .
155
+ type is < code > ExecutionPolicy&& </ code > .
156
156
</ p >
157
157
158
158
< p >
@@ -329,7 +329,7 @@ <h1>Header <code><experimental/algorithm></code> synopsis</h1>
329
329
namespace parallel {
330
330
template<class ExecutionPolicy,
331
331
class InputIterator, class Function>
332
- void for_each(ExecutionPolicy&& exec,
332
+ void for_each(ExecutionPolicy&& exec,
333
333
InputIterator first, InputIterator last,
334
334
Function f);
335
335
template<class InputIterator, class Size, class Function>
@@ -348,7 +348,7 @@ <h1>For each</h1>
348
348
< cxx-signature >
349
349
template<class ExecutionPolicy,
350
350
class InputIterator, class Function>
351
- void for_each(ExecutionPolicy&& exec,
351
+ void for_each(ExecutionPolicy&& exec,
352
352
InputIterator first, InputIterator last,
353
353
Function f);
354
354
</ cxx-signature >
0 commit comments