mirror of https://github.com/AxioDL/metaforce.git
SpecMP3: Prevent unnecessary copies
Prevents iterating over elements by value and also uses auto to ensure the iterated item matches 1:1.
This commit is contained in:
parent
315becf1b5
commit
94c4c0f102
|
@ -132,7 +132,7 @@ struct SpecMP3 : SpecBase {
|
|||
}
|
||||
|
||||
/* Assemble extract report */
|
||||
for (const std::pair<std::string, DNAMP3::PAKBridge*>& item : fe ? m_feOrderedPaks : m_orderedPaks) {
|
||||
for (const auto& item : fe ? m_feOrderedPaks : m_orderedPaks) {
|
||||
if (!item.second->m_doExtract)
|
||||
continue;
|
||||
rep.childOpts.emplace_back();
|
||||
|
@ -394,7 +394,7 @@ struct SpecMP3 : SpecBase {
|
|||
progress.startNewLine();
|
||||
|
||||
hecl::ClientProcess process;
|
||||
for (std::pair<std::string, DNAMP3::PAKBridge*> pair : m_feOrderedPaks) {
|
||||
for (auto& pair : m_feOrderedPaks) {
|
||||
DNAMP3::PAKBridge& pak = *pair.second;
|
||||
if (!pak.m_doExtract)
|
||||
continue;
|
||||
|
|
Loading…
Reference in New Issue