VideoCommon/TextureCacheBase: Use emplace_back where applicable

Same thing, less code.
This commit is contained in:
Lioncash 2019-08-04 23:28:11 -04:00
parent fd12ae1408
commit d52dd2e04f
1 changed files with 4 additions and 4 deletions

View File

@ -553,16 +553,16 @@ void TextureCacheBase::DoSaveState(PointerWrap& p)
{
if (ShouldSaveEntry(it.second))
{
u32 id = AddCacheEntryToMap(it.second);
textures_by_address_list.push_back(std::make_pair(it.first, id));
const u32 id = AddCacheEntryToMap(it.second);
textures_by_address_list.emplace_back(it.first, id);
}
}
for (const auto& it : textures_by_hash)
{
if (ShouldSaveEntry(it.second))
{
u32 id = AddCacheEntryToMap(it.second);
textures_by_hash_list.push_back(std::make_pair(it.first, id));
const u32 id = AddCacheEntryToMap(it.second);
textures_by_hash_list.emplace_back(it.first, id);
}
}
}