1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-07-17 21:35:11 +00:00

assert macro OK (#755)

* create assert macro and replace a bunch of __assert

Signed-off-by: angie <angheloalf95@gmail.com>

* Another bunch of assert

Signed-off-by: angie <angheloalf95@gmail.com>

* more assert

Signed-off-by: angie <angheloalf95@gmail.com>

* assert(false)

Signed-off-by: angie <angheloalf95@gmail.com>

* last assert used in matching code

Signed-off-by: angie <angheloalf95@gmail.com>

* the non-matchings

Signed-off-by: angie <angheloalf95@gmail.com>

* typo

Signed-off-by: angie <angheloalf95@gmail.com>

* format

Signed-off-by: angie <angheloalf95@gmail.com>

* change macro to uppercase

Signed-off-by: angie <angheloalf95@gmail.com>

* Apply suggestions from code review

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>

* Change ASSERT(false) to ASSERT(0)

Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com>
This commit is contained in:
Anghelo Carvajal 2021-04-29 14:39:46 -04:00 committed by GitHub
parent 0b8252cfe9
commit 98aef8988a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
44 changed files with 148 additions and 301 deletions

View file

@ -95,10 +95,7 @@ void VisMono_Draw(VisMono* this, Gfx** gfxp) {
LOG_ADDRESS("mono_dl + (1+3+1+1+80*(7+2+2+3)+1)", monoDL + DLSIZE, "../z_vismono.c", 259);
LOG_ADDRESS("(1+3+1+1+80*(7+2+2+3)+1)", DLSIZE, "../z_vismono.c", 260);
}
if (!(glistpEnd <= monoDL + DLSIZE)) {
__assert("glistp_end <= mono_dl + DLSIZE", "../z_vismono.c", 262);
}
ASSERT(glistpEnd <= monoDL + DLSIZE, "glistp_end <= mono_dl + DLSIZE", "../z_vismono.c", 262);
}
gDPPipeSync(gfx++);
@ -128,8 +125,6 @@ void VisMono_DrawOld(VisMono* this) {
if (!this->monoDl) {
this->monoDl = SystemArena_MallocDebug(DLSIZE * sizeof(Gfx), "../z_vismono.c", 289);
glistpEnd = VisMono_DrawTexture(this, this->monoDl);
if (!(glistpEnd <= this->monoDl + DLSIZE)) {
__assert("glistp_end <= this->mono_dl + DLSIZE", "../z_vismono.c", 292);
}
ASSERT(glistpEnd <= this->monoDl + DLSIZE, "glistp_end <= this->mono_dl + DLSIZE", "../z_vismono.c", 292);
}
}