command: add missing ptrCast

While a lot of values will implicitly coerce to this field value,
slices annoyingly do not and thus the explicit cast is required.
This commit is contained in:
2023-08-04 00:15:29 -07:00
parent 29175d07ce
commit d091de5686

View File

@@ -358,7 +358,7 @@ pub fn CommandBuilder(comptime UserContext: type) type {
fields = fields ++ &[_]StructField{.{
.name = param.name,
.type = FieldType,
.default_value = default,
.default_value = @ptrCast(default),
.is_comptime = false,
.alignment = @alignOf(FieldType),
}};