mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-08-02 14:57:31 +03:00
Zig 0.14: StructField holds default values as pointers
This commit is contained in:
@ -66,7 +66,7 @@ pub fn build(b: *std.Build) !void {
|
|||||||
// it to the `LIBXML_{field}_ENABLED` C define where field is uppercased.
|
// it to the `LIBXML_{field}_ENABLED` C define where field is uppercased.
|
||||||
inline for (std.meta.fields(Options)) |field| {
|
inline for (std.meta.fields(Options)) |field| {
|
||||||
const opt = b.option(bool, field.name, "Configure flag") orelse
|
const opt = b.option(bool, field.name, "Configure flag") orelse
|
||||||
@as(*const bool, @ptrCast(field.default_value.?)).*;
|
@as(*const bool, @ptrCast(field.default_value_ptr.?)).*;
|
||||||
if (opt) {
|
if (opt) {
|
||||||
var nameBuf: [32]u8 = undefined;
|
var nameBuf: [32]u8 = undefined;
|
||||||
const name = std.ascii.upperString(&nameBuf, field.name);
|
const name = std.ascii.upperString(&nameBuf, field.name);
|
||||||
|
Reference in New Issue
Block a user