#Get name of Module

1 messages · Page 1 of 1 (latest)

burnt mirage
#

Is there a way in 0.13 to get the name of a std.Build.Module ?

#

e.g. "uuid" after I've created a module with const uuid_module: *Module = b.addModule(name: "uuid", options: .{ .root_source_file: ?LazyPath = b.path("src/main.zig"), .target: ?ResolvedTarget = target, .optimize: ?OptimizeMode = optimize, });

hot wing
#

I don't think a module itself has a name (b.createModule does not take a name as an argument). You could use the modules field of std.Build, which is a std.StringArrayHashMap(*Module).