|
|
|
@ -126,10 +126,6 @@ pub fn MyList(comptime T: type) type {
|
|
|
|
|
|
|
|
|
|
// Driver Code
|
|
|
|
|
pub fn main() !void {
|
|
|
|
|
// 查看本地CPU架构和操作系统信息
|
|
|
|
|
var native_target_info = try std.zig.system.NativeTargetInfo.detect(std.zig.CrossTarget{});
|
|
|
|
|
std.debug.print("Native Info: CPU Arch = {}, OS = {}\n", .{native_target_info.target.cpu.arch, native_target_info.target.os.tag});
|
|
|
|
|
|
|
|
|
|
// 初始化列表
|
|
|
|
|
var list = MyList(i32){};
|
|
|
|
|
try list.init(std.heap.page_allocator);
|
|
|
|
|