ActionReplay: Make use of std::erase_if
This commit is contained in:
parent
50e4dc5dba
commit
84ae0c1c7e
|
@ -997,13 +997,11 @@ void RunAllActive(const Core::CPUThreadGuard& cpu_guard)
|
||||||
// are only atomic ops unless contested. It should be rare for this to
|
// are only atomic ops unless contested. It should be rare for this to
|
||||||
// be contested.
|
// be contested.
|
||||||
std::lock_guard guard(s_lock);
|
std::lock_guard guard(s_lock);
|
||||||
s_active_codes.erase(std::remove_if(s_active_codes.begin(), s_active_codes.end(),
|
std::erase_if(s_active_codes, [&cpu_guard](const ARCode& code) {
|
||||||
[&cpu_guard](const ARCode& code) {
|
const bool success = RunCodeLocked(cpu_guard, code);
|
||||||
bool success = RunCodeLocked(cpu_guard, code);
|
LogInfo("\n");
|
||||||
LogInfo("\n");
|
return !success;
|
||||||
return !success;
|
});
|
||||||
}),
|
|
||||||
s_active_codes.end());
|
|
||||||
s_disable_logging = true;
|
s_disable_logging = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue