Refactor Zig imports and file structure (part 1) (#21270)

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
taylor.fish
2025-07-22 17:51:38 -07:00
committed by GitHub
parent 73d92c7518
commit 07cd45deae
564 changed files with 9917 additions and 9697 deletions

View File

@@ -2,7 +2,7 @@ const HTTPThread = @This();
var custom_ssl_context_map = std.AutoArrayHashMap(*SSLConfig, *NewHTTPContext(true)).init(bun.default_allocator);
loop: *JSC.MiniEventLoop,
loop: *jsc.MiniEventLoop,
http_context: NewHTTPContext(false),
https_context: NewHTTPContext(true),
@@ -198,7 +198,7 @@ pub fn onStart(opts: InitOpts) void {
bun.http.default_arena = Arena.init() catch unreachable;
bun.http.default_allocator = bun.http.default_arena.allocator();
const loop = bun.JSC.MiniEventLoop.initGlobal(null);
const loop = bun.jsc.MiniEventLoop.initGlobal(null);
if (Environment.isWindows) {
_ = std.process.getenvW(comptime bun.strings.w("SystemRoot")) orelse {
@@ -462,21 +462,22 @@ pub const Queue = UnboundedQueue(AsyncHTTP, .next);
const log = Output.scoped(.HTTPThread, false);
const stringZ = [:0]const u8;
const ProxyTunnel = @import("./ProxyTunnel.zig");
const std = @import("std");
const Arena = @import("../allocators/mimalloc_arena.zig").Arena;
const SSLConfig = @import("../bun.js/api/server.zig").ServerConfig.SSLConfig;
const bun = @import("bun");
const Environment = bun.Environment;
const Global = bun.Global;
const JSC = bun.JSC;
const Output = bun.Output;
const stringZ = bun.stringZ;
const jsc = bun.jsc;
const strings = bun.strings;
const uws = bun.uws;
const Arena = bun.allocators.MimallocArena;
const Batch = bun.ThreadPool.Batch;
const UnboundedQueue = bun.threading.UnboundedQueue;
const SSLConfig = bun.api.server.ServerConfig.SSLConfig;
const HTTPClient = bun.http;
const AsyncHTTP = bun.http.AsyncHTTP;