diff options
Diffstat (limited to 'src/z/root.zig')
| -rw-r--r-- | src/z/root.zig | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/z/root.zig b/src/z/root.zig index 6ca6302..fc42acd 100644 --- a/src/z/root.zig +++ b/src/z/root.zig @@ -1,4 +1,5 @@ const builtin = @import("builtin"); +const std = @import("std"); const wasm = wasm_struct: { if (builtin.target.cpu.arch.isWasm()) { @@ -10,10 +11,19 @@ const wasm = wasm_struct: { }; } - break :wasm_struct struct {}; + break :wasm_struct struct { + pub const Env = struct { + pub const Object = struct {}; + }; + }; }; pub const env = wasm.env; pub const Env = wasm.Env; -pub const app = @import("app/root.zig"); +pub const App = @import("App/root.zig").App; + +pub const allocator: std.mem.Allocator = if (builtin.target.cpu.arch.isWasm()) .{ + .ptr = undefined, + .vtable = &std.heap.BrkAllocator.vtable, +} else .failing; |