From 4957536e23e772aca711bb1c96518733d94a4cb1 Mon Sep 17 00:00:00 2001 From: Kayne Ruse Date: Thu, 23 Apr 2026 10:45:01 +1000 Subject: [PATCH] When in doubt, typecast --- repl/bytecode_inspector.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/repl/bytecode_inspector.c b/repl/bytecode_inspector.c index 38aa886..7a2b95e 100644 --- a/repl/bytecode_inspector.c +++ b/repl/bytecode_inspector.c @@ -14,14 +14,9 @@ int inspect_read(unsigned char* bytecode, unsigned int pc, unsigned int jumps_ad #define ISPRINT_SANITIZE(x) (isprint((int)x) > 0 ? (x) : '_') #define MARKER_VALUE(pc, type) \ - (pc * sizeof(type)) - -#if TOY_BITNESS == 64 - #define MARKER "\t\033[" TOY_CC_FONT_BLACK "m" " %lu\t" TOY_CC_RESET -#else - #define MARKER "\t\033[" TOY_CC_FONT_BLACK "m" " %llu\t" TOY_CC_RESET -#endif + ((unsigned int)(pc * sizeof(type))) +#define MARKER "\t\033[" TOY_CC_FONT_BLACK "m" " %u\t" TOY_CC_RESET #define FONT_BLACK "\033[" TOY_CC_FONT_BLACK "m" //exposed functions