mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-08 07:51:28 +12:00
Replace verify() with ensure() with auto src location.
Expression ensure(x) returns x. Using comma operator removed.
This commit is contained in:
parent
38745e5782
commit
e055d16b2c
121 changed files with 693 additions and 690 deletions
|
@ -464,7 +464,7 @@ void cpu_thread::operator()()
|
|||
if (progress == umax && std::exchange(wait_set, false))
|
||||
{
|
||||
// Operation finished: need to clean wait flag
|
||||
verify(HERE), !_cpu->check_state();
|
||||
ensure(!_cpu->check_state());
|
||||
return;
|
||||
}
|
||||
});
|
||||
|
@ -484,7 +484,7 @@ void cpu_thread::operator()()
|
|||
|
||||
if (progress == umax && std::exchange(wait_set, false))
|
||||
{
|
||||
verify(HERE), !_cpu->check_state();
|
||||
ensure(!_cpu->check_state());
|
||||
return;
|
||||
}
|
||||
};
|
||||
|
@ -693,7 +693,7 @@ bool cpu_thread::check_state() noexcept
|
|||
cpu_counter::add(this);
|
||||
}
|
||||
|
||||
verify(HERE), cpu_can_stop || !retval;
|
||||
ensure(cpu_can_stop || !retval);
|
||||
return retval;
|
||||
}
|
||||
|
||||
|
@ -859,7 +859,7 @@ std::string cpu_thread::dump_misc() const
|
|||
bool cpu_thread::suspend_work::push(cpu_thread* _this) noexcept
|
||||
{
|
||||
// Can't allow pre-set wait bit (it'd be a problem)
|
||||
verify(HERE), !_this || !(_this->state & cpu_flag::wait);
|
||||
ensure(!_this || !(_this->state & cpu_flag::wait));
|
||||
|
||||
do
|
||||
{
|
||||
|
@ -998,7 +998,7 @@ bool cpu_thread::suspend_work::push(cpu_thread* _this) noexcept
|
|||
}
|
||||
|
||||
// Finalization (last increment)
|
||||
verify(HERE), g_suspend_counter++ & 1;
|
||||
ensure(g_suspend_counter++ & 1);
|
||||
|
||||
cpu_counter::for_all_cpu(copy2, [&](cpu_thread* cpu)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue