mirror of
https://github.com/luanti-org/luanti.git
synced 2025-07-02 16:38:41 +00:00
Value copy / allocation optimizations mostly in server, SAO and serialize code
This commit is contained in:
parent
2fd5f38c45
commit
471e567657
16 changed files with 52 additions and 64 deletions
|
@ -167,7 +167,7 @@ std::map<std::string, ModSpec> getModsInPath(
|
|||
return result;
|
||||
}
|
||||
|
||||
std::vector<ModSpec> flattenMods(std::map<std::string, ModSpec> mods)
|
||||
std::vector<ModSpec> flattenMods(const std::map<std::string, ModSpec> &mods)
|
||||
{
|
||||
std::vector<ModSpec> result;
|
||||
for (const auto &it : mods) {
|
||||
|
|
|
@ -68,7 +68,7 @@ std::map<std::string, ModSpec> getModsInPath(
|
|||
const std::string &path, bool part_of_modpack = false);
|
||||
|
||||
// replaces modpack Modspecs with their content
|
||||
std::vector<ModSpec> flattenMods(std::map<std::string, ModSpec> mods);
|
||||
std::vector<ModSpec> flattenMods(const std::map<std::string, ModSpec> &mods);
|
||||
|
||||
// a ModConfiguration is a subset of installed mods, expected to have
|
||||
// all dependencies fullfilled, so it can be used as a list of mods to
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue