mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2025-07-20 23:25:46 +00:00
common/assert: add unlikely
This commit is contained in:
parent
f3fd1038bb
commit
855928b782
1 changed files with 1 additions and 1 deletions
|
@ -7,7 +7,7 @@
|
||||||
#include "common/settings.h"
|
#include "common/settings.h"
|
||||||
|
|
||||||
void assert_check_condition(bool cond, std::function<void()>&& on_failure) {
|
void assert_check_condition(bool cond, std::function<void()>&& on_failure) {
|
||||||
if (!cond) {
|
if (!cond) [[unlikely]] {
|
||||||
on_failure();
|
on_failure();
|
||||||
|
|
||||||
if (Settings::values.use_debug_asserts) {
|
if (Settings::values.use_debug_asserts) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue