mirror of
https://github.com/davisking/dlib.git
synced 2024-11-01 10:14:53 +08:00
Changed code slightly to avoid a bug in gcc 4.1.2
This commit is contained in:
parent
99a9c2760a
commit
94d1e7874f
@ -227,7 +227,8 @@ void example_without_using_lambda_functions()
|
||||
|
||||
int sum = 0;
|
||||
vect.assign(10, 2);
|
||||
parallel_for(num_threads, 0, vect.size(), function_object_sum(vect, sum));
|
||||
function_object_sum funct(vect, sum);
|
||||
parallel_for(num_threads, 0, vect.size(), funct);
|
||||
cout << "sum: " << sum << endl;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user