summaryrefslogtreecommitdiff
path: root/_tests
diff options
context:
space:
mode:
Diffstat (limited to '_tests')
-rw-r--r--_tests/test.zig27
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;