Posted in

Go标准库json.Marshal对map[string]interface{}的深层行为解析:为什么时间戳变字符串、float64精度丢失?

第一章:Go标准库json.Ma … Go标准库json.Marshal对map[string]interface{}的深层行为解析:为什么时间戳变字符串、float64精度丢失?Read more

Posted in

Go中map转JSON必须知道的3个隐藏约束:struct不能含func/chans/unsafe.Pointer,且所有字段需满足json.Marshaler契约

第一章:Go中map内struc … Go中map转JSON必须知道的3个隐藏约束:struct不能含func/chans/unsafe.Pointer,且所有字段需满足json.Marshaler契约Read more

Posted in

Go map内struct转JSON总多出{}或[]?3分钟定位:是json.RawMessage误用、还是UnmarshalJSON未实现、抑或sync.Map并发写入污染?

第一章:Go map内struc … Go map内struct转JSON总多出{}或[]?3分钟定位:是json.RawMessage误用、还是UnmarshalJSON未实现、抑或sync.Map并发写入污染?Read more