aboutsummaryrefslogtreecommitdiff
path: root/src/main.zig
diff options
context:
space:
mode:
authorVeikka Tuominen <git@vexu.eu>2024-01-28 00:30:24 +0200
committerVeikka Tuominen <git@vexu.eu>2024-02-01 15:22:36 +0200
commit220d3264c929187cb72111fcf75a223f9e4a7399 (patch)
tree9eb71fb86133145d0b962074e13a00d043260bf1 /src/main.zig
parent776cd673f206099012d789fd5d05d49dd72b9faa (diff)
downloadzig-220d3264c929187cb72111fcf75a223f9e4a7399.tar.gz
zig-220d3264c929187cb72111fcf75a223f9e4a7399.zip
std: make options a struct instance instead of a namespace
Diffstat (limited to 'src/main.zig')
-rw-r--r--src/main.zig12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/main.zig b/src/main.zig
index 8eef42698d..a6bc747d2b 100644
--- a/src/main.zig
+++ b/src/main.zig
@@ -29,16 +29,16 @@ const AstGen = @import("AstGen.zig");
const mingw = @import("mingw.zig");
const Server = std.zig.Server;
-pub const std_options = struct {
- pub const wasiCwd = wasi_cwd;
- pub const logFn = log;
- pub const enable_segfault_handler = false;
+pub const std_options = .{
+ .wasiCwd = wasi_cwd,
+ .logFn = log,
+ .enable_segfault_handler = false,
- pub const log_level: std.log.Level = switch (builtin.mode) {
+ .log_level = switch (builtin.mode) {
.Debug => .debug,
.ReleaseSafe, .ReleaseFast => .info,
.ReleaseSmall => .err,
- };
+ },
};
// Crash report needs to override the panic handler