polyadvent

A game engine from scratch in C
git clone git://jb55.com/polyadvent
Log | Files | Refs | README

commit a89e975fc593d70d429ddf5872cf9d9cac54af6c
parent a1c28cdfcf48983de4891b321d9f36ee15e28348
Author: William Casarin <jb55@jb55.com>
Date:   Sun, 21 Jul 2019 20:20:48 -0700

int array_size

Diffstat:
Msrc/util.h | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/util.h b/src/util.h @@ -26,7 +26,7 @@ #define RAD(x) ((x)*TAU/360.0) #define EPSILON 0.0001 -#define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0])) +#define ARRAY_SIZE(x) ((int)(sizeof(x) / sizeof((x)[0]))) #define min(a,b) (a < b ? a : b) #define max(a,b) (a > b ? a : b) #define streq(a,b) (strcmp(a,b) == 0)