From d52dd2e04f9e6e5dd7c690e5a485d7b32d61e7de Mon Sep 17 00:00:00 2001 From: Lioncash Date: Sun, 4 Aug 2019 23:28:11 -0400 Subject: [PATCH] VideoCommon/TextureCacheBase: Use emplace_back where applicable Same thing, less code. --- Source/Core/VideoCommon/TextureCacheBase.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Source/Core/VideoCommon/TextureCacheBase.cpp b/Source/Core/VideoCommon/TextureCacheBase.cpp index b9b59145ff..10f3b9f293 100644 --- a/Source/Core/VideoCommon/TextureCacheBase.cpp +++ b/Source/Core/VideoCommon/TextureCacheBase.cpp @@ -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); } } }