chore: update json marshal tests

This commit is contained in:
yusing
2025-04-17 05:18:11 +08:00
parent d7f8359f27
commit af8bf197c9
3 changed files with 622 additions and 62 deletions

View File

@@ -108,7 +108,7 @@ func appendUint(v reflect.Value, buf []byte) []byte {
}
func appendFloat(v reflect.Value, buf []byte) []byte {
return strconv.AppendFloat(buf, v.Float(), 'f', 2, 64)
return strconv.AppendFloat(buf, v.Float(), 'f', -1, 64)
}
func appendWithCustomMarshaler(v reflect.Value, buf []byte) (res []byte, ok bool) {