From eb1d61d04fbe33141dad00d4eef10fe124234b50 Mon Sep 17 00:00:00 2001 From: xbzk Date: Tue, 17 Feb 2026 13:36:13 +0100 Subject: [PATCH] Update src/common/assert.h NINJA REPORTS THIS SHIT ALMOST EVERY STEP! The reason, any mention to UNIMPLEMENTED() macro reaches this point where a constant expression (macro argument) is not declared so. Since it's an unimplemented() feature assert call, i`ve just made it non constant. No charges. [161/863] Building CXX object src\hid_core\CMakeFiles\hid_core.dir\frontend\input_interpreter.cpp.obj D:\dev\eden\src\.\core/hle/kernel/k_auto_object.h(100): warning C4127: conditional expression is constant D:\dev\eden\src\.\core/hle/kernel/k_auto_object.h(100): note: consider using 'if constexpr' statement instead D:\dev\eden\src\.\core/hle/kernel/k_memory_manager.h(246): warning C4127: conditional expression is constant D:\dev\eden\src\.\core/hle/kernel/k_memory_manager.h(246): note: consider using 'if constexpr' statement instead Signed-off-by: xbzk --- src/common/assert.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/common/assert.h b/src/common/assert.h index f720f90f15..67310f8e06 100644 --- a/src/common/assert.h +++ b/src/common/assert.h @@ -25,7 +25,8 @@ void AssertFailSoftImpl(); #define ASSERT_MSG(_a_, ...) \ ([&]() YUZU_NO_INLINE { \ - if (!(_a_)) [[unlikely]] { \ + auto&& assert_condition = (_a_); \ + if (!(assert_condition)) [[unlikely]] { \ LOG_CRITICAL(Debug, __FILE__ ": assert " __VA_ARGS__); \ AssertFailSoftImpl(); \ } \