bootstrap

This commit is contained in:
2026-02-09 10:56:15 -06:00
parent 0503acb7e6
commit e04ab4c30c
7 changed files with 131 additions and 77 deletions

View File

@@ -10655,7 +10655,8 @@ static JSValue js_mach_eval (JSContext *ctx, JSValue this_val, int argc, JSValue
return JS_ThrowSyntaxError (ctx, "mach_eval: failed to parse AST");
}
JSValue result = JS_RunMachTree (ctx, ast, JS_NULL);
JSValue env = (argc >= 3 && JS_IsObject (argv[2])) ? argv[2] : JS_NULL;
JSValue result = JS_RunMachTree (ctx, ast, env);
cJSON_Delete (ast);
JS_FreeCString (ctx, name);
return result;