Fix: Unintentional move from constant in retrieve_attributes_for_transfer

Moving a constant variable results in a copy occurring instead. This
looks to have been an accidental change as part of ea937b304d.

A few tools will warn about this:
`Warning	C26478	Don't use std::move on constant variables. (es.56)`
`Warning	cpp:S5415	"std::move" should not be called on a const object.`

Pull Request: https://projects.blender.org/blender/blender/pulls/121063
This commit is contained in:
Jesse Yurkovich
2024-04-25 18:02:50 +02:00
committed by Jesse Yurkovich
parent 9a530906cf
commit fea1d1d71f

View File

@@ -811,7 +811,7 @@ Vector<AttributeTransferData> retrieve_attributes_for_transfer(
return true;
}
const GVArray src = *src_attributes.lookup(id, meta_data.domain);
GVArray src = *src_attributes.lookup(id, meta_data.domain);
GSpanAttributeWriter dst = dst_attributes.lookup_or_add_for_write_only_span(
id, meta_data.domain, meta_data.data_type);
attributes.append({std::move(src), meta_data, std::move(dst)});