mirror of
https://github.com/oven-sh/bun
synced 2026-02-18 14:51:52 +00:00
22 lines
671 B
Zig
22 lines
671 B
Zig
pub fn write(data: []const u8) void {
|
|
if (comptime bun.Environment.isDebug) {
|
|
DebugSocketMonitorWriter.check.call();
|
|
if (DebugSocketMonitorWriter.enabled) {
|
|
DebugSocketMonitorWriter.write(data);
|
|
}
|
|
}
|
|
}
|
|
|
|
pub fn read(data: []const u8) void {
|
|
if (comptime bun.Environment.isDebug) {
|
|
DebugSocketMonitorReader.check.call();
|
|
if (DebugSocketMonitorReader.enabled) {
|
|
DebugSocketMonitorReader.write(data);
|
|
}
|
|
}
|
|
}
|
|
|
|
const DebugSocketMonitorReader = @import("./DebugSocketMonitorReader.zig");
|
|
const DebugSocketMonitorWriter = @import("./DebugSocketMonitorWriter.zig");
|
|
const bun = @import("bun");
|