easy comptime hooks

This commit is contained in:
2024-07-09 23:35:40 -04:00
parent cb8684cbf3
commit cc1a9fdabc
5 changed files with 69 additions and 68 deletions

View File

@@ -11,8 +11,17 @@ pub const nu_options: nu.Options = .{
},
};
pub const nu_driver = nu.Window;
// todo declare or infer module dependencies, topological sort for init order. clean up "init" lines in main.
//
// problem: where should gpa go? probably some "Engine" structure in nu.zig
//
// don't necessarily need to declare topological sort - depth-first traversal
// of each module's dependencies without repeats would do.
//
// idea - use a structure like std.Build.Step where the polymorphic part is a
// component of the larger structure.
pub const nu_driver = nu.Window;
pub const nu_modules = .{
App,
nu.ImGui,
@@ -24,15 +33,6 @@ pub fn main() !void {
defer _ = gpa.detectLeaks();
const alloc = gpa.allocator();
// todo declare or infer module dependencies, topological sort for init order
// problem: where should gpa go? probably some "Engine" structure in nu.zig
// don't necessarily need to declare topological sort - depth-first traversal
// of each module's dependencies without repeats would do.
// idea - use a structure like std.Build.Step where the polymorphic part is a
// component of the larger structure.
try nu.Window.init(alloc);
defer nu.Window.deinit();