Fixed json null value parsing

This commit is contained in:
Courtney Strachan
2025-03-02 07:57:23 -08:00
parent b9b27bc1e0
commit dbbe96ae5c

View File

@@ -176,7 +176,13 @@ marshal_to_writer :: proc(w: io.Writer, v: any, opt: ^Marshal_Options) -> (err:
return .Unsupported_Type
case runtime.Type_Info_Pointer:
return .Unsupported_Type
ptr := a.(rawptr)
if ptr == nil {
io.write_string(w, "null") or_return
} else {
return .Unsupported_Type
}
case runtime.Type_Info_Multi_Pointer:
return .Unsupported_Type