Cleanup: avoid positional struct initialization
When moving to C++ field for initialization was removed. Favor assignments to field names as it reads better and avoids bugs if files are ever re-arranged as well as mistakes (see T94784). Note that the generated optimized output is identical with GCC11.
This commit is contained in:
parent
abf30007ab
commit
c69a581c0b
|
@ -386,7 +386,10 @@ static Vector<WeldVert> weld_vert_ctx_alloc_and_setup(Span<int> vert_dest_map,
|
|||
|
||||
for (const int i : vert_dest_map.index_range()) {
|
||||
if (vert_dest_map[i] != OUT_OF_CONTEXT) {
|
||||
wvert.append({vert_dest_map[i], i});
|
||||
WeldVert wv{};
|
||||
wv.vert_dest = vert_dest_map[i];
|
||||
wv.vert_orig = i;
|
||||
wvert.append(wv);
|
||||
}
|
||||
}
|
||||
return wvert;
|
||||
|
|
Loading…
Reference in New Issue