mirror of
https://github.com/zeldaret/tww.git
synced 2026-07-07 05:14:58 -04:00
Fix JUT_ASSERT to use double defines
We know JUT_ASSERT originally had double defines because defines such as NULL and ARRAY_SIZE are expanded in assertion strings, as discovered by Jasper: https://godbolt.org/z/PvqsG9asb
This commit is contained in:
@@ -4,7 +4,9 @@
|
||||
#include "dolphin/types.h"
|
||||
#include "dolphin/os/OS.h"
|
||||
|
||||
#define JUT_ASSERT(LINE, COND) (void)((COND) || (JUTAssertion::showAssert(JUTAssertion::getSDevice(), __FILE__, LINE, #COND), OSPanic(__FILE__, LINE, "Halt"), 0));
|
||||
#define JUT_SHOW_ASSERT(LINE, COND) JUTAssertion::showAssert(JUTAssertion::getSDevice(), __FILE__, LINE, #COND)
|
||||
|
||||
#define JUT_ASSERT(LINE, COND) (void)((COND) || (JUT_SHOW_ASSERT(LINE, COND), OSPanic(__FILE__, LINE, "Halt"), 0));
|
||||
|
||||
// Favored by JAI (JAudio)
|
||||
#define JUT_ASSERT_MSG(LINE, COND, MSG) \
|
||||
|
||||
@@ -11,7 +11,7 @@ s32 LOAD_COPYDATE(void*);
|
||||
|
||||
extern OSThread mainThread;
|
||||
|
||||
#define HeapCheckTableNum 6
|
||||
const int HeapCheckTableNum = 6;
|
||||
|
||||
class HeapCheck {
|
||||
public:
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
#include "d/actor/d_a_bomb2.h"
|
||||
#include "JSystem/JUtility/JUTAssert.h"
|
||||
|
||||
#define L_daBomb_Version 1
|
||||
const int L_daBomb_Version = 1;
|
||||
|
||||
/* 80067FA0-80067FD0 .text getBombRestTime__8daBomb_cFv */
|
||||
s16 daBomb_c::getBombRestTime() {
|
||||
|
||||
Reference in New Issue
Block a user