diff options
| author | Taylan Kammer <taylan.kammer@gmail.com> | 2026-06-28 23:17:02 +0200 |
|---|---|---|
| committer | Taylan Kammer <taylan.kammer@gmail.com> | 2026-06-28 23:17:02 +0200 |
| commit | 594e34e1145e0b23a685e1685a181751dd5d0044 (patch) | |
| tree | daaa8f459e0e9434a22698433066cb5abf43ad11 /_tests | |
| parent | d129b1fe89866d540e4a6faeee7433b6ad51be4a (diff) | |
Yet another NaN-packing design change.
Diffstat (limited to '_tests')
| -rw-r--r-- | _tests/test.zig | 27 |
1 files changed, 23 insertions, 4 deletions
diff --git a/_tests/test.zig b/_tests/test.zig index 6a61827..b96cf05 100644 --- a/_tests/test.zig +++ b/_tests/test.zig @@ -4,10 +4,29 @@ const std = @import("std"); // const MyList = List(u8, .fromByteUnits(1 << 20)); -pub export fn main(argc: c_int, argv: [*]const [*:0]const u8) c_int { - const arr: [argc]u8 = undefined; - arr[0] = argv[0][0]; - std.debug.print("{}\n", .{arr[0]}); +pub fn main() u8 { + const Test = struct { + foo: struct { + pub fn blub() void { + std.debug.print("nah\n", .{}); + } + + bar: u64 = 0, + + pub fn blah(x: @This()) void { + _ = x; + std.debug.print("\nyeah\n", .{}); + } + + baz: u64 = 0, + } = .{}, + }; + + (Test{}).foo.blah(); + + // const arr: [argc]u8 = undefined; + // arr[0] = argv[0][0]; + // std.debug.print("{}\n", .{arr[0]}); // const alloc = std.heap.smp_allocator; |
