diff --git a/src/obj_list.c b/src/obj_list.c index 1c23897..957428b 100644 --- a/src/obj_list.c +++ b/src/obj_list.c @@ -7,7 +7,7 @@ #define LIST_WRAP_INDEX() \ if (index < 0) index += self->values.count; \ - if (unlikely(index < 0 || index >= (krk_integer_type)self->values.count)) return krk_runtimeError(vm.exceptions->indexError, "list index out of range: " PRIkrk_int, index) + if (unlikely(index < 0 || index >= (krk_integer_type)self->values.count)) return krk_runtimeError(vm.exceptions->indexError, "list index out of range: %zd", (ssize_t)index) #define LIST_WRAP_SOFT(val) \ if (val < 0) val += self->values.count; \ diff --git a/src/obj_tuple.c b/src/obj_tuple.c index a51dee4..9c88d53 100644 --- a/src/obj_tuple.c +++ b/src/obj_tuple.c @@ -7,7 +7,7 @@ #define TUPLE_WRAP_INDEX() \ if (index < 0) index += self->values.count; \ - if (index < 0 || index >= (krk_integer_type)self->values.count) return krk_runtimeError(vm.exceptions->indexError, "tuple index out of range: " PRIkrk_int, index) + if (index < 0 || index >= (krk_integer_type)self->values.count) return krk_runtimeError(vm.exceptions->indexError, "tuple index out of range: %zd", (ssize_t)index) static int _tuple_init_callback(void * context, const KrkValue * values, size_t count) { KrkValueArray * positionals = context;