| ... | ... | @@ -43,7 +43,7 @@ fn anyTag(self: *Encoder, tag_: Tag, val: anytype) !void { |
| 43 | 43 | const is_default = if (f_attrs.@"comptime") false else if (f_attrs.defaultValue(f_type)) |default_val| brk: { |
| 44 | 44 | break :brk std.mem.eql(u8, std.mem.asBytes(&default_val), std.mem.asBytes(&field_val)); |
| 45 | 45 | } else false; |
| 46 | | const is_null_optional = if (@typeInfo(f.type) == .optional) field_val == null else false; |
| 46 | const is_null_optional = if (@typeInfo(f_type) == .optional) field_val == null else false; |
| 47 | 47 | |
| 48 | 48 | if (!is_default and !is_null_optional) { |
| 49 | 49 | const start2 = self.buffer.data.len; |