mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-12 16:15:20 +02:00
Remove unnecessary copy of a big data structure
This commit is contained in:
@@ -73,7 +73,7 @@ struct MapEditEvent
|
||||
modified_blocks.push_back(getNodeBlockPos(pos));
|
||||
}
|
||||
|
||||
void setModifiedBlocks(const std::map<v3s16, MapBlock *> blocks)
|
||||
void setModifiedBlocks(const std::map<v3s16, MapBlock *>& blocks)
|
||||
{
|
||||
assert(modified_blocks.empty()); // only meant for initialization (once)
|
||||
modified_blocks.reserve(blocks.size());
|
||||
|
Reference in New Issue
Block a user