diff options
| author | LLLL Colonq <llll@colonq> | 2025-10-06 05:06:16 -0400 |
|---|---|---|
| committer | LLLL Colonq <llll@colonq> | 2025-10-06 05:06:41 -0400 |
| commit | 09435bffe025a96e0d9c3b44ee9c505973b383bd (patch) | |
| tree | d352772edc096a374d42c50ffa4a7b2b8dad59dd /src/utils.h | |
| parent | 063ab38ce78c370c698e5d148bb9f993ee731ddb (diff) | |
Cleanup, fix bugs
Ensure everything builds on C89
Diffstat (limited to 'src/utils.h')
| -rw-r--r-- | src/utils.h | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/utils.h b/src/utils.h index 9a740e5..303055a 100644 --- a/src/utils.h +++ b/src/utils.h @@ -3,13 +3,11 @@ #include <stdckdint.h> -void pit_panic_(const char *format, ...); -void pit_debug_(const char *format, ...); #define PIT_STRSTR(x) #x #define PIT_STR(x) PIT_STRSTR(x) -#define pit_panic(format, ...) pit_panic_("error [" __FILE__ ":" PIT_STR(__LINE__) "] " format "\n" __VA_OPT__(,) __VA_ARGS__) -#define pit_debug(format, ...) pit_debug_("[" __FILE__ ":" PIT_STR(__LINE__) "] " format "\n" __VA_OPT__(,) __VA_ARGS__) -#define pit_mul(result, a, b) if (ckd_mul(result, a, b)) pit_panic("integer overflow during multiplication"); +void pit_panic(const char *format, ...); +void pit_debug(const char *format, ...); +#define pit_mul(result, a, b) if (ckd_mul(result, a, b)) pit_panic("integer overflow during multiplication%s",""); #endif |
