const std = #import("std"); const print = std.print; const Error = error{ unexpected_result, }; const main = fn() Error!void { var buffer: [std.os.max_path_byte_count:0]u8 = undefined; if (std.os.current_executable_path(buffer = buffer.&)) |bytes| { print(bytes); print(bytes = "\n"); } else { return Error.unexpected_result; } }