rm bigint

This commit is contained in:
2026-01-23 15:05:57 -06:00
parent 36833db2c9
commit beea76949c
3 changed files with 5 additions and 4 deletions

View File

@@ -5389,6 +5389,7 @@ static void gc_free_cycles(JSRuntime *rt)
switch(p->gc_obj_type) {
case JS_GC_OBJ_TYPE_JS_OBJECT:
case JS_GC_OBJ_TYPE_FUNCTION_BYTECODE:
case JS_GC_OBJ_TYPE_ARRAY:
#ifdef DUMP_GC_FREE
if (!header_done) {
printf("Freeing cycles:\n");
@@ -6902,11 +6903,13 @@ static int JS_SetPropertyValue(JSContext *ctx, JSValueConst this_obj, JSValue pr
JSArray *arr = JS_VALUE_GET_ARRAY(this_obj);
int32_t signed_idx = JS_VALUE_GET_INT(prop);
if (signed_idx < 0) {
JS_FreeValue(ctx, prop);
JS_FreeValue(ctx, val);
JS_ThrowRangeError(ctx, "array index %d out of bounds (length %u)",
signed_idx, arr->len);
return -1;
}
JS_FreeValue(ctx,prop);
return js_intrinsic_array_set(ctx, arr, (uint32_t)signed_idx, val);
}
@@ -10465,7 +10468,7 @@ static JSValue JS_CallInternal(JSContext *caller_ctx, JSValueConst func_obj,
goto exception;
call_argv = sp - call_argc;
for (i = 0; i < call_argc; i++) {
JS_SetPropertyNumber(ctx, ret_val, i, call_argv[i]);
ret = JS_SetPropertyNumber(ctx, ret_val, i, call_argv[i]);
call_argv[i] = JS_NULL;
if (ret < 0) {
JS_FreeValue(ctx, ret_val);