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
+4 -4
View File
@@ -3,7 +3,7 @@
*
*/
#include "d/dolzel_rel.h"
#include "d/dolzel_rel.h" // IWYU pragma: keep
#include "d/actor/d_a_obj_gpTaru.h"
#include "d/actor/d_a_obj_eff.h"
@@ -53,7 +53,7 @@ void daGpTaru_c::setBaseMtx() {
/* 8057D2D0-8057D33C 0002F0 006C+00 1/0 0/0 0/0 .text CreateHeap__10daGpTaru_cFv */
int daGpTaru_c::CreateHeap() {
J3DModelData* modelData = (J3DModelData*)dComIfG_getObjectRes("K_ktar00", 3);
JUT_ASSERT(295, modelData != 0);
JUT_ASSERT(295, modelData != NULL);
mpModel = mDoExt_J3DModel__create(modelData, J3DMdlFlag_DifferedDLBuffer, BMD_DEFAULT_DIFF_FLAGS);
if (mpModel == NULL) {
@@ -403,7 +403,7 @@ void daGpTaru_c::mode_proc_roll() {
bool var_r26 = fopAcM_gc_c::gndCheck(&sp38);
bool found_tripla = fopAcM_gc_c::getTriPla(&tripla);
if (-1000000000.0f != gnd_height && found_tripla) {
if (-G_CM3D_F_INF != gnd_height && found_tripla) {
f32 temp_f28 = cM_scos(cM_deg2s(temp_f30 - 0.5f));
sp2C = tripla.mNormal;
if (sp2C.y < temp_f28) {
@@ -556,7 +556,7 @@ void daGpTaru_c::breakEffSet() {
cXyz size(0.75f, 0.75f, 0.75f);
J3DModelData* kibako_bmd = (J3DModelData*)dComIfG_getObjectRes("Always", "BreakWoodBox.bmd");
JUT_ASSERT(1259, kibako_bmd != 0);
JUT_ASSERT(1259, kibako_bmd != NULL);
JPABaseEmitter* emt_p = dComIfGp_particle_set(dPa_RM(ID_ZF_S_M_EXBARREL00BOARD), &pos, NULL, NULL, 0xFF, &dPa_modelEcallBack::getEcallback(), fopAcM_GetRoomNo(this), NULL, NULL, &size);
dPa_modelEcallBack::setModel(emt_p, kibako_bmd, tevStr, 3, NULL, 0, 0);