mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-15 00:06:09 +03:00
warn if the binary is a debug build
This commit is contained in:
@ -22,6 +22,12 @@ const Ghostty = @import("main_c.zig").Ghostty;
|
|||||||
pub var state: GlobalState = undefined;
|
pub var state: GlobalState = undefined;
|
||||||
|
|
||||||
pub fn main() !void {
|
pub fn main() !void {
|
||||||
|
if (comptime builtin.mode == .Debug) {
|
||||||
|
std.log.warn("This is a debug build. Performance will be very poor.", .{});
|
||||||
|
std.log.warn("You should only use a debug build for developing Ghostty.", .{});
|
||||||
|
std.log.warn("Otherwise, please rebuild in a release mode.", .{});
|
||||||
|
}
|
||||||
|
|
||||||
state.init();
|
state.init();
|
||||||
defer state.deinit();
|
defer state.deinit();
|
||||||
const alloc = state.alloc;
|
const alloc = state.alloc;
|
||||||
|
Reference in New Issue
Block a user