mirror of
https://github.com/isocpp/CppCoreGuidelines.git
synced 2025-12-17 04:44:34 +03:00
* Update for Issue 1763 * add copy case * Add 'DataRecord'
This commit is contained in:
@@ -10449,7 +10449,10 @@ Flag variable and constant declarations with multiple declarators (e.g., `int* p
|
||||
|
||||
Consider:
|
||||
|
||||
auto p = v.begin(); // vector<int>::iterator
|
||||
auto p = v.begin(); // vector<DataRecord>::iterator
|
||||
auto z1 = v[3]; // makes copy of DataRecord
|
||||
auto& z2 = v[3]; // avoids copy
|
||||
const auto& z3 = v[3]; // const and avoids copy
|
||||
auto h = t.future();
|
||||
auto q = make_unique<int[]>(s);
|
||||
auto f = [](int x) { return x + 10; };
|
||||
|
||||
Reference in New Issue
Block a user