mirror of
https://github.com/ziglang/zig.git
synced 2025-12-06 06:13:07 +00:00
This library contains: - The global constants as used by C code. - An Insn struct that implements can generate all the BPF instructions. - A simple BPF virtual machine implementation that can be used for testing programs. This has complete code-coverage and has been extensively fuzzed.
20 lines
476 B
Zig
20 lines
476 B
Zig
const std = @import("std.zig");
|
|
|
|
pub const os = struct {
|
|
pub const Socket = @import("x/os/socket.zig").Socket;
|
|
pub usingnamespace @import("x/os/io.zig");
|
|
pub usingnamespace @import("x/os/net.zig");
|
|
};
|
|
|
|
pub const net = struct {
|
|
pub const ip = @import("x/net/ip.zig");
|
|
pub const tcp = @import("x/net/tcp.zig");
|
|
pub const bpf = @import("x/net/bpf.zig");
|
|
};
|
|
|
|
test {
|
|
inline for (.{ os, net }) |module| {
|
|
std.testing.refAllDecls(module);
|
|
}
|
|
}
|