Fix JUT_ASSERT and several other macros (#2711)

* Fix JUT_ASSERT to be a nested define

* Switch names that appear in asserts to be constants instead of defines

* Replace `0` in asserts with `NULL` or `FALSE`

* Fix fpclassify

* Fix ARRAY_SIZE

* Use G_CM3D_F_INF

* More fixes for fpclassify

* Remove FLOAT_LABEL

* Remove incorrect FLAG_ON macro

* Remove UNK_BSS macro

* Silence clangd unused header warning for PCH
This commit is contained in:
LagoLunatic
2025-09-28 16:11:07 -04:00
committed by GitHub
parent 737250d7f5
commit 6ec6fce8cb
1008 changed files with 3172 additions and 3237 deletions
+9 -9
View File
@@ -3,7 +3,7 @@
*
*/
#include "d/dolzel_rel.h"
#include "d/dolzel_rel.h" // IWYU pragma: keep
#include "d/actor/d_a_npc_prayer.h"
#include "d/d_com_inf_game.h"
@@ -163,7 +163,7 @@ int daNpcPray_c::Create() {
/* 80AB348C-80AB3610 00078C 0184+00 1/1 0/0 0/0 .text CreateHeap__11daNpcPray_cFv */
int daNpcPray_c::CreateHeap() {
J3DModelData* mdlData_p = (J3DModelData*)dComIfG_getObjectRes(l_arcNames[0], 9);
JUT_ASSERT(313, 0 != mdlData_p);
JUT_ASSERT(313, NULL != mdlData_p);
mpMorf = new mDoExt_McaMorfSO(mdlData_p, NULL, NULL, NULL, -1, 1.0f, 0, -1, &mSound, 0x80000, 0x11000084);
if (mpMorf != NULL && mpMorf->getModel() == NULL) {
@@ -582,7 +582,7 @@ bool daNpcPray_c::wait(void*) {
break;
case 1:
case 3:
JUT_ASSERT(1076, 0);
JUT_ASSERT(1076, FALSE);
break;
}
@@ -608,7 +608,7 @@ bool daNpcPray_c::fear(void*) {
break;
case 1:
case 3:
JUT_ASSERT(1076, 0);
JUT_ASSERT(1076, FALSE);
break;
}
@@ -672,7 +672,7 @@ bool daNpcPray_c::talk(void*) {
}
break;
default:
JUT_ASSERT(1209, 0);
JUT_ASSERT(1209, FALSE);
}
return var_r28;
@@ -695,7 +695,7 @@ bool daNpcPray_c::demo(void*) {
if (staffID != -1) {
mStaffID = staffID;
JUT_ASSERT(1243, 0 != mEvtSeqList[mOrderEvtNo]);
JUT_ASSERT(1243, NULL != mEvtSeqList[mOrderEvtNo]);
if ((this->*mEvtSeqList[mOrderEvtNo])(staffID)) {
evtmgr.cutEnd(staffID);
var_r25 = 1;
@@ -721,7 +721,7 @@ bool daNpcPray_c::demo(void*) {
}
break;
case 3:
JUT_ASSERT(1280, 0);
JUT_ASSERT(1280, FALSE);
break;
}
@@ -777,7 +777,7 @@ BOOL daNpcPray_c::_Evt_GetHeart_CutInit(const int& i_cutId) {
break;
}
default:
JUT_ASSERT(1396, 0);
JUT_ASSERT(1396, FALSE);
break;
}
@@ -830,7 +830,7 @@ BOOL daNpcPray_c::_Evt_GetHeart_CutMain(int const& i_cutId) {
break;
}
default:
JUT_ASSERT(1474, 0);
JUT_ASSERT(1474, FALSE);
var_r28 = 1;
break;
}