From 4b079cfb92969a481455b16ec796ed5a9e1e237f Mon Sep 17 00:00:00 2001 From: Conor Patrick Date: Thu, 20 Feb 2025 09:27:07 -0500 Subject: [PATCH] change module name to github.com/bytedance/sonic --- Makefile | 2 +- benchmarks/bench_test.go | 2 +- benchmarks/decode_test.go | 2 +- benchmarks/encode_test.go | 2 +- benchmarks/go.mod | 4 ++-- benchmarks/path_test.go | 2 +- benchmarks/slow_reader_test.go | 2 +- color.go | 4 ++-- color_test.go | 4 ++-- decode.go | 8 ++++---- decode_test.go | 6 +++--- encode.go | 12 ++++++------ encode_test.go | 4 ++-- error.go | 4 ++-- export_test.go | 4 ++-- go.mod | 2 +- helper_test.go | 2 +- internal/cmd/generator/vm.go.tmpl | 4 ++-- internal/decoder/anonymous_field.go | 2 +- internal/decoder/array.go | 4 ++-- internal/decoder/bool.go | 2 +- internal/decoder/bytes.go | 4 ++-- internal/decoder/compile.go | 2 +- internal/decoder/compile_norace.go | 2 +- internal/decoder/compile_race.go | 2 +- internal/decoder/context.go | 2 +- internal/decoder/float.go | 2 +- internal/decoder/func.go | 4 ++-- internal/decoder/int.go | 4 ++-- internal/decoder/interface.go | 4 ++-- internal/decoder/invalid.go | 4 ++-- internal/decoder/map.go | 6 +++--- internal/decoder/number.go | 2 +- internal/decoder/path.go | 4 ++-- internal/decoder/ptr.go | 2 +- internal/decoder/slice.go | 4 ++-- internal/decoder/stream.go | 2 +- internal/decoder/string.go | 2 +- internal/decoder/struct.go | 2 +- internal/decoder/uint.go | 4 ++-- internal/decoder/unmarshal_json.go | 4 ++-- internal/decoder/unmarshal_text.go | 4 ++-- internal/decoder/wrapped_string.go | 2 +- internal/encoder/code.go | 2 +- internal/encoder/compact.go | 2 +- internal/encoder/compiler.go | 6 +++--- internal/encoder/context.go | 2 +- internal/encoder/encoder.go | 4 ++-- internal/encoder/indent.go | 2 +- internal/encoder/opcode.go | 2 +- internal/encoder/vm/debug_vm.go | 2 +- internal/encoder/vm/hack.go | 2 +- internal/encoder/vm/util.go | 4 ++-- internal/encoder/vm/vm.go | 4 ++-- internal/encoder/vm_color/debug_vm.go | 2 +- internal/encoder/vm_color/hack.go | 2 +- internal/encoder/vm_color/util.go | 4 ++-- internal/encoder/vm_color/vm.go | 4 ++-- internal/encoder/vm_color_indent/debug_vm.go | 2 +- internal/encoder/vm_color_indent/util.go | 4 ++-- internal/encoder/vm_color_indent/vm.go | 4 ++-- internal/encoder/vm_indent/debug_vm.go | 2 +- internal/encoder/vm_indent/hack.go | 2 +- internal/encoder/vm_indent/util.go | 4 ++-- internal/encoder/vm_indent/vm.go | 4 ++-- json.go | 4 ++-- json_test.go | 4 ++-- number_test.go | 4 ++-- option.go | 6 +++--- path.go | 4 ++-- path_test.go | 4 ++-- query.go | 4 ++-- query_test.go | 4 ++-- size_test.go | 4 ++-- stream_test.go | 5 ++--- tagkey_test.go | 4 ++-- test/cover/cover_array_test.go | 2 +- test/cover/cover_bool_test.go | 2 +- test/cover/cover_bytes_test.go | 2 +- test/cover/cover_float32_test.go | 2 +- test/cover/cover_float64_test.go | 2 +- test/cover/cover_helper_test.go | 2 +- test/cover/cover_int16_test.go | 2 +- test/cover/cover_int32_test.go | 2 +- test/cover/cover_int64_test.go | 2 +- test/cover/cover_int8_test.go | 2 +- test/cover/cover_int_test.go | 2 +- test/cover/cover_map_test.go | 2 +- test/cover/cover_marshal_json_test.go | 2 +- test/cover/cover_marshal_text_test.go | 2 +- test/cover/cover_number_test.go | 2 +- test/cover/cover_slice_test.go | 2 +- test/cover/cover_string_test.go | 2 +- test/cover/cover_uint16_test.go | 2 +- test/cover/cover_uint32_test.go | 2 +- test/cover/cover_uint64_test.go | 2 +- test/cover/cover_uint8_test.go | 2 +- test/cover/cover_uint_test.go | 2 +- test/example/example_marshaling_test.go | 2 +- test/example/example_query_test.go | 2 +- test/example/example_test.go | 2 +- test/example/example_text_marshaling_test.go | 2 +- 102 files changed, 155 insertions(+), 156 deletions(-) diff --git a/Makefile b/Makefile index c030577d..6efcdd1b 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -PKG := github.com/goccy/go-json +PKG := github.com/bytedance/sonic BIN_DIR := $(CURDIR)/bin PKGS := $(shell go list ./... | grep -v internal/cmd|grep -v test) diff --git a/benchmarks/bench_test.go b/benchmarks/bench_test.go index d45331be..8947c7cc 100644 --- a/benchmarks/bench_test.go +++ b/benchmarks/bench_test.go @@ -21,7 +21,7 @@ import ( stdjson "encoding/json" - "github.com/goccy/go-json" + "github.com/bytedance/sonic" jsoniter "github.com/json-iterator/go" segmentiojson "github.com/segmentio/encoding/json" "github.com/wI2L/jettison" diff --git a/benchmarks/decode_test.go b/benchmarks/decode_test.go index 5f2a4c23..31231bc1 100644 --- a/benchmarks/decode_test.go +++ b/benchmarks/decode_test.go @@ -6,7 +6,7 @@ import ( "testing" gojay "github.com/francoispqt/gojay" - gojson "github.com/goccy/go-json" + gojson "github.com/bytedance/sonic" jsoniter "github.com/json-iterator/go" segmentiojson "github.com/segmentio/encoding/json" fastjson "github.com/valyala/fastjson" diff --git a/benchmarks/encode_test.go b/benchmarks/encode_test.go index 1e8938c8..8f13aa7e 100644 --- a/benchmarks/encode_test.go +++ b/benchmarks/encode_test.go @@ -7,7 +7,7 @@ import ( "testing" gojay "github.com/francoispqt/gojay" - gojson "github.com/goccy/go-json" + gojson "github.com/bytedance/sonic" jsoniter "github.com/json-iterator/go" "github.com/pquerna/ffjson/ffjson" segmentiojson "github.com/segmentio/encoding/json" diff --git a/benchmarks/go.mod b/benchmarks/go.mod index 6fd858ef..ffc97b23 100644 --- a/benchmarks/go.mod +++ b/benchmarks/go.mod @@ -4,7 +4,7 @@ go 1.19 require ( github.com/francoispqt/gojay v1.2.13 - github.com/goccy/go-json v0.0.0-00010101000000-000000000000 + github.com/bytedance/sonic v0.0.0-00010101000000-000000000000 github.com/json-iterator/go v1.1.10 github.com/mailru/easyjson v0.0.0-20190312143242-1de009706dbe github.com/pquerna/ffjson v0.0.0-20190930134022-aa0246cd15f7 @@ -19,4 +19,4 @@ require ( github.com/stretchr/testify v1.7.0 // indirect ) -replace github.com/goccy/go-json => ../ +replace github.com/bytedance/sonic => ../ diff --git a/benchmarks/path_test.go b/benchmarks/path_test.go index 3224b657..93544f6f 100644 --- a/benchmarks/path_test.go +++ b/benchmarks/path_test.go @@ -3,7 +3,7 @@ package benchmark import ( "testing" - gojson "github.com/goccy/go-json" + gojson "github.com/bytedance/sonic" ) func Benchmark_Decode_SmallStruct_UnmarshalPath_GoJson(b *testing.B) { diff --git a/benchmarks/slow_reader_test.go b/benchmarks/slow_reader_test.go index bd9623c7..aadc7cc1 100644 --- a/benchmarks/slow_reader_test.go +++ b/benchmarks/slow_reader_test.go @@ -7,7 +7,7 @@ import ( "reflect" "testing" - gojson "github.com/goccy/go-json" + gojson "github.com/bytedance/sonic" ) // Benchmark decoding from a slow io.Reader that never fills the buffer completely diff --git a/color.go b/color.go index e80b22b4..d7de88f7 100644 --- a/color.go +++ b/color.go @@ -1,9 +1,9 @@ -package json +package sonic import ( "fmt" - "github.com/goccy/go-json/internal/encoder" + "github.com/bytedance/sonic/internal/encoder" ) type ( diff --git a/color_test.go b/color_test.go index c21819dc..c6410696 100644 --- a/color_test.go +++ b/color_test.go @@ -1,9 +1,9 @@ -package json_test +package sonic_test import ( "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestColorize(t *testing.T) { diff --git a/decode.go b/decode.go index 74c6ac3b..feb33122 100644 --- a/decode.go +++ b/decode.go @@ -1,4 +1,4 @@ -package json +package sonic import ( "context" @@ -7,9 +7,9 @@ import ( "reflect" "unsafe" - "github.com/goccy/go-json/internal/decoder" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/decoder" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type Decoder struct { diff --git a/decode_test.go b/decode_test.go index 8f32cedb..c075b648 100644 --- a/decode_test.go +++ b/decode_test.go @@ -1,4 +1,4 @@ -package json_test +package sonic_test import ( "bytes" @@ -18,7 +18,7 @@ import ( "time" "unsafe" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func Test_Decoder(t *testing.T) { @@ -123,7 +123,7 @@ func Test_Decoder(t *testing.T) { assertEq(t, "map.c", v["c"], 3) assertEq(t, "map.d", v["d"], 4) t.Run("nested map", func(t *testing.T) { - // https://github.com/goccy/go-json/issues/8 + // https://github.com/bytedance/sonic/issues/8 content := ` { "a": { diff --git a/encode.go b/encode.go index c5173825..661761e3 100644 --- a/encode.go +++ b/encode.go @@ -1,4 +1,4 @@ -package json +package sonic import ( "context" @@ -6,11 +6,11 @@ import ( "os" "unsafe" - "github.com/goccy/go-json/internal/encoder" - "github.com/goccy/go-json/internal/encoder/vm" - "github.com/goccy/go-json/internal/encoder/vm_color" - "github.com/goccy/go-json/internal/encoder/vm_color_indent" - "github.com/goccy/go-json/internal/encoder/vm_indent" + "github.com/bytedance/sonic/internal/encoder" + "github.com/bytedance/sonic/internal/encoder/vm" + "github.com/bytedance/sonic/internal/encoder/vm_color" + "github.com/bytedance/sonic/internal/encoder/vm_color_indent" + "github.com/bytedance/sonic/internal/encoder/vm_indent" ) // An Encoder writes JSON values to an output stream. diff --git a/encode_test.go b/encode_test.go index ede05684..8282d435 100644 --- a/encode_test.go +++ b/encode_test.go @@ -1,4 +1,4 @@ -package json_test +package sonic_test import ( "bytes" @@ -18,7 +18,7 @@ import ( "testing" "time" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type recursiveT struct { diff --git a/error.go b/error.go index 5b2dcee5..d690da06 100644 --- a/error.go +++ b/error.go @@ -1,7 +1,7 @@ -package json +package sonic import ( - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) // Before Go 1.2, an InvalidUTF8Error was returned by Marshal when diff --git a/export_test.go b/export_test.go index 526f9b21..5dc3af9e 100644 --- a/export_test.go +++ b/export_test.go @@ -1,7 +1,7 @@ -package json +package sonic import ( - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) var ( diff --git a/go.mod b/go.mod index f5b57ff7..07d2710f 100644 --- a/go.mod +++ b/go.mod @@ -1,3 +1,3 @@ -module github.com/goccy/go-json +module github.com/bytedance/sonic go 1.19 diff --git a/helper_test.go b/helper_test.go index 53157ce9..42532469 100644 --- a/helper_test.go +++ b/helper_test.go @@ -1,4 +1,4 @@ -package json_test +package sonic_test import "testing" diff --git a/internal/cmd/generator/vm.go.tmpl b/internal/cmd/generator/vm.go.tmpl index 645d20f9..71aea49a 100644 --- a/internal/cmd/generator/vm.go.tmpl +++ b/internal/cmd/generator/vm.go.tmpl @@ -7,8 +7,8 @@ import ( "sort" "unsafe" - "github.com/goccy/go-json/internal/encoder" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/encoder" + "github.com/bytedance/sonic/internal/runtime" ) func Run(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]byte, error) { diff --git a/internal/decoder/anonymous_field.go b/internal/decoder/anonymous_field.go index b6876cf0..d5241bb4 100644 --- a/internal/decoder/anonymous_field.go +++ b/internal/decoder/anonymous_field.go @@ -3,7 +3,7 @@ package decoder import ( "unsafe" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/runtime" ) type anonymousFieldDecoder struct { diff --git a/internal/decoder/array.go b/internal/decoder/array.go index 4b23ed43..1223d597 100644 --- a/internal/decoder/array.go +++ b/internal/decoder/array.go @@ -4,8 +4,8 @@ import ( "fmt" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type arrayDecoder struct { diff --git a/internal/decoder/bool.go b/internal/decoder/bool.go index ba6cf5bc..0d1c7690 100644 --- a/internal/decoder/bool.go +++ b/internal/decoder/bool.go @@ -4,7 +4,7 @@ import ( "fmt" "unsafe" - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) type boolDecoder struct { diff --git a/internal/decoder/bytes.go b/internal/decoder/bytes.go index 939bf432..9932352c 100644 --- a/internal/decoder/bytes.go +++ b/internal/decoder/bytes.go @@ -5,8 +5,8 @@ import ( "fmt" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type bytesDecoder struct { diff --git a/internal/decoder/compile.go b/internal/decoder/compile.go index 8ad50936..3adb2e0f 100644 --- a/internal/decoder/compile.go +++ b/internal/decoder/compile.go @@ -10,7 +10,7 @@ import ( "unicode" "unsafe" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/runtime" ) var ( diff --git a/internal/decoder/compile_norace.go b/internal/decoder/compile_norace.go index 025ca85b..7cbf3c00 100644 --- a/internal/decoder/compile_norace.go +++ b/internal/decoder/compile_norace.go @@ -6,7 +6,7 @@ package decoder import ( "unsafe" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/runtime" ) func CompileToGetDecoder(typ *runtime.Type) (Decoder, error) { diff --git a/internal/decoder/compile_race.go b/internal/decoder/compile_race.go index 023b817c..fa7f58d9 100644 --- a/internal/decoder/compile_race.go +++ b/internal/decoder/compile_race.go @@ -7,7 +7,7 @@ import ( "sync" "unsafe" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/runtime" ) var decMu sync.RWMutex diff --git a/internal/decoder/context.go b/internal/decoder/context.go index cb2ffdaf..1982445d 100644 --- a/internal/decoder/context.go +++ b/internal/decoder/context.go @@ -4,7 +4,7 @@ import ( "sync" "unsafe" - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) type RuntimeContext struct { diff --git a/internal/decoder/float.go b/internal/decoder/float.go index 9b2eb8b3..276a0994 100644 --- a/internal/decoder/float.go +++ b/internal/decoder/float.go @@ -4,7 +4,7 @@ import ( "strconv" "unsafe" - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) type floatDecoder struct { diff --git a/internal/decoder/func.go b/internal/decoder/func.go index 4cc12ca8..3691b9f0 100644 --- a/internal/decoder/func.go +++ b/internal/decoder/func.go @@ -5,8 +5,8 @@ import ( "fmt" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type funcDecoder struct { diff --git a/internal/decoder/int.go b/internal/decoder/int.go index 1a7f0819..df9df2e1 100644 --- a/internal/decoder/int.go +++ b/internal/decoder/int.go @@ -5,8 +5,8 @@ import ( "reflect" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type intDecoder struct { diff --git a/internal/decoder/interface.go b/internal/decoder/interface.go index 45c69ab8..5e9c7b31 100644 --- a/internal/decoder/interface.go +++ b/internal/decoder/interface.go @@ -7,8 +7,8 @@ import ( "reflect" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type interfaceDecoder struct { diff --git a/internal/decoder/invalid.go b/internal/decoder/invalid.go index 4c9721b0..a1fbca7a 100644 --- a/internal/decoder/invalid.go +++ b/internal/decoder/invalid.go @@ -4,8 +4,8 @@ import ( "reflect" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type invalidDecoder struct { diff --git a/internal/decoder/map.go b/internal/decoder/map.go index 07a9caea..2a309aa8 100644 --- a/internal/decoder/map.go +++ b/internal/decoder/map.go @@ -4,8 +4,8 @@ import ( "reflect" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type mapDecoder struct { @@ -36,7 +36,7 @@ const ( mapMaxElemSize = 128 ) -// See detail: https://github.com/goccy/go-json/pull/283 +// See detail: https://github.com/bytedance/sonic/pull/283 func canUseAssignFaststrType(key *runtime.Type, value *runtime.Type) bool { indirectElem := value.Size() > mapMaxElemSize if indirectElem { diff --git a/internal/decoder/number.go b/internal/decoder/number.go index 10e5435e..b1bf2a0f 100644 --- a/internal/decoder/number.go +++ b/internal/decoder/number.go @@ -5,7 +5,7 @@ import ( "strconv" "unsafe" - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) type numberDecoder struct { diff --git a/internal/decoder/path.go b/internal/decoder/path.go index a15ff69e..b413721f 100644 --- a/internal/decoder/path.go +++ b/internal/decoder/path.go @@ -5,8 +5,8 @@ import ( "reflect" "strconv" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type PathString string diff --git a/internal/decoder/ptr.go b/internal/decoder/ptr.go index ae229946..4f03bf08 100644 --- a/internal/decoder/ptr.go +++ b/internal/decoder/ptr.go @@ -4,7 +4,7 @@ import ( "fmt" "unsafe" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/runtime" ) type ptrDecoder struct { diff --git a/internal/decoder/slice.go b/internal/decoder/slice.go index 30a23e4b..b1b2b089 100644 --- a/internal/decoder/slice.go +++ b/internal/decoder/slice.go @@ -5,8 +5,8 @@ import ( "sync" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) var ( diff --git a/internal/decoder/stream.go b/internal/decoder/stream.go index a383f725..3fb0895d 100644 --- a/internal/decoder/stream.go +++ b/internal/decoder/stream.go @@ -7,7 +7,7 @@ import ( "strconv" "unsafe" - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) const ( diff --git a/internal/decoder/string.go b/internal/decoder/string.go index 32602c90..f8716ca0 100644 --- a/internal/decoder/string.go +++ b/internal/decoder/string.go @@ -9,7 +9,7 @@ import ( "unicode/utf8" "unsafe" - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) type stringDecoder struct { diff --git a/internal/decoder/struct.go b/internal/decoder/struct.go index 313da153..621d06ac 100644 --- a/internal/decoder/struct.go +++ b/internal/decoder/struct.go @@ -10,7 +10,7 @@ import ( "unicode/utf16" "unsafe" - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) type structFieldSet struct { diff --git a/internal/decoder/uint.go b/internal/decoder/uint.go index 4131731b..e2ea0c35 100644 --- a/internal/decoder/uint.go +++ b/internal/decoder/uint.go @@ -5,8 +5,8 @@ import ( "reflect" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type uintDecoder struct { diff --git a/internal/decoder/unmarshal_json.go b/internal/decoder/unmarshal_json.go index 4cd6dbd5..85e45e22 100644 --- a/internal/decoder/unmarshal_json.go +++ b/internal/decoder/unmarshal_json.go @@ -6,8 +6,8 @@ import ( "fmt" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type unmarshalJSONDecoder struct { diff --git a/internal/decoder/unmarshal_text.go b/internal/decoder/unmarshal_text.go index d711d0f8..286b0658 100644 --- a/internal/decoder/unmarshal_text.go +++ b/internal/decoder/unmarshal_text.go @@ -9,8 +9,8 @@ import ( "unicode/utf8" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type unmarshalTextDecoder struct { diff --git a/internal/decoder/wrapped_string.go b/internal/decoder/wrapped_string.go index 0c4e2e6e..438dc287 100644 --- a/internal/decoder/wrapped_string.go +++ b/internal/decoder/wrapped_string.go @@ -5,7 +5,7 @@ import ( "reflect" "unsafe" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/runtime" ) type wrappedStringDecoder struct { diff --git a/internal/encoder/code.go b/internal/encoder/code.go index 5b08faef..6f468a94 100644 --- a/internal/encoder/code.go +++ b/internal/encoder/code.go @@ -5,7 +5,7 @@ import ( "reflect" "unsafe" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/runtime" ) type Code interface { diff --git a/internal/encoder/compact.go b/internal/encoder/compact.go index e287a6c0..7a3e6a86 100644 --- a/internal/encoder/compact.go +++ b/internal/encoder/compact.go @@ -6,7 +6,7 @@ import ( "strconv" "unsafe" - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) var ( diff --git a/internal/encoder/compiler.go b/internal/encoder/compiler.go index b1076368..e4b9c6a7 100644 --- a/internal/encoder/compiler.go +++ b/internal/encoder/compiler.go @@ -9,8 +9,8 @@ import ( "sync/atomic" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) type marshalerContext interface { @@ -493,7 +493,7 @@ func (c *Compiler) listElemCode(typ *runtime.Type) (Code, error) { default: // isPtr was originally used to indicate whether the type of top level is pointer. // However, since the slice/array element is a specification that can get the pointer address, explicitly set isPtr to true. - // See here for related issues: https://github.com/goccy/go-json/issues/370 + // See here for related issues: https://github.com/bytedance/sonic/issues/370 code, err := c.typeToCodeWithPtr(typ, true) if err != nil { return nil, err diff --git a/internal/encoder/context.go b/internal/encoder/context.go index 3833d0c8..0a7bd64e 100644 --- a/internal/encoder/context.go +++ b/internal/encoder/context.go @@ -5,7 +5,7 @@ import ( "sync" "unsafe" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/runtime" ) type compileContext struct { diff --git a/internal/encoder/encoder.go b/internal/encoder/encoder.go index b436f5b2..d5291884 100644 --- a/internal/encoder/encoder.go +++ b/internal/encoder/encoder.go @@ -13,8 +13,8 @@ import ( "sync" "unsafe" - "github.com/goccy/go-json/internal/errors" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/errors" + "github.com/bytedance/sonic/internal/runtime" ) func (t OpType) IsMultipleOpHead() bool { diff --git a/internal/encoder/indent.go b/internal/encoder/indent.go index dfe04b5e..8b07e990 100644 --- a/internal/encoder/indent.go +++ b/internal/encoder/indent.go @@ -4,7 +4,7 @@ import ( "bytes" "fmt" - "github.com/goccy/go-json/internal/errors" + "github.com/bytedance/sonic/internal/errors" ) func takeIndentSrcRuntimeContext(src []byte) (*RuntimeContext, []byte) { diff --git a/internal/encoder/opcode.go b/internal/encoder/opcode.go index df22f554..a281c57d 100644 --- a/internal/encoder/opcode.go +++ b/internal/encoder/opcode.go @@ -7,7 +7,7 @@ import ( "strings" "unsafe" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/runtime" ) const uintptrSize = 4 << (^uintptr(0) >> 63) diff --git a/internal/encoder/vm/debug_vm.go b/internal/encoder/vm/debug_vm.go index 82b6dd47..fb3ef72d 100644 --- a/internal/encoder/vm/debug_vm.go +++ b/internal/encoder/vm/debug_vm.go @@ -4,7 +4,7 @@ import ( "fmt" "io" - "github.com/goccy/go-json/internal/encoder" + "github.com/bytedance/sonic/internal/encoder" ) func DebugRun(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]byte, error) { diff --git a/internal/encoder/vm/hack.go b/internal/encoder/vm/hack.go index 65252b4a..16bbf1c8 100644 --- a/internal/encoder/vm/hack.go +++ b/internal/encoder/vm/hack.go @@ -5,5 +5,5 @@ import ( // `vm`, `vm_indent`, `vm_color`, `vm_color_indent` packages uses a lot of memory to compile, // so forcibly make dependencies and avoid compiling in concurrent. // dependency order: vm => vm_indent => vm_color => vm_color_indent - _ "github.com/goccy/go-json/internal/encoder/vm_indent" + _ "github.com/bytedance/sonic/internal/encoder/vm_indent" ) diff --git a/internal/encoder/vm/util.go b/internal/encoder/vm/util.go index 86291d7b..e041b660 100644 --- a/internal/encoder/vm/util.go +++ b/internal/encoder/vm/util.go @@ -5,8 +5,8 @@ import ( "fmt" "unsafe" - "github.com/goccy/go-json/internal/encoder" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/encoder" + "github.com/bytedance/sonic/internal/runtime" ) const uintptrSize = 4 << (^uintptr(0) >> 63) diff --git a/internal/encoder/vm/vm.go b/internal/encoder/vm/vm.go index 645d20f9..71aea49a 100644 --- a/internal/encoder/vm/vm.go +++ b/internal/encoder/vm/vm.go @@ -7,8 +7,8 @@ import ( "sort" "unsafe" - "github.com/goccy/go-json/internal/encoder" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/encoder" + "github.com/bytedance/sonic/internal/runtime" ) func Run(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]byte, error) { diff --git a/internal/encoder/vm_color/debug_vm.go b/internal/encoder/vm_color/debug_vm.go index 925f61ed..5f24e2c2 100644 --- a/internal/encoder/vm_color/debug_vm.go +++ b/internal/encoder/vm_color/debug_vm.go @@ -3,7 +3,7 @@ package vm_color import ( "fmt" - "github.com/goccy/go-json/internal/encoder" + "github.com/bytedance/sonic/internal/encoder" ) func DebugRun(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]byte, error) { diff --git a/internal/encoder/vm_color/hack.go b/internal/encoder/vm_color/hack.go index 12ec56c5..1bb1aa42 100644 --- a/internal/encoder/vm_color/hack.go +++ b/internal/encoder/vm_color/hack.go @@ -5,5 +5,5 @@ import ( // `vm`, `vm_indent`, `vm_color`, `vm_color_indent` packages uses a lot of memory to compile, // so forcibly make dependencies and avoid compiling in concurrent. // dependency order: vm => vm_indent => vm_color => vm_color_indent - _ "github.com/goccy/go-json/internal/encoder/vm_color_indent" + _ "github.com/bytedance/sonic/internal/encoder/vm_color_indent" ) diff --git a/internal/encoder/vm_color/util.go b/internal/encoder/vm_color/util.go index 33f29aee..73e4c0e3 100644 --- a/internal/encoder/vm_color/util.go +++ b/internal/encoder/vm_color/util.go @@ -5,8 +5,8 @@ import ( "fmt" "unsafe" - "github.com/goccy/go-json/internal/encoder" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/encoder" + "github.com/bytedance/sonic/internal/runtime" ) const uintptrSize = 4 << (^uintptr(0) >> 63) diff --git a/internal/encoder/vm_color/vm.go b/internal/encoder/vm_color/vm.go index a63e83e5..da2f894c 100644 --- a/internal/encoder/vm_color/vm.go +++ b/internal/encoder/vm_color/vm.go @@ -7,8 +7,8 @@ import ( "sort" "unsafe" - "github.com/goccy/go-json/internal/encoder" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/encoder" + "github.com/bytedance/sonic/internal/runtime" ) func Run(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]byte, error) { diff --git a/internal/encoder/vm_color_indent/debug_vm.go b/internal/encoder/vm_color_indent/debug_vm.go index dd4cd489..41b294ea 100644 --- a/internal/encoder/vm_color_indent/debug_vm.go +++ b/internal/encoder/vm_color_indent/debug_vm.go @@ -3,7 +3,7 @@ package vm_color_indent import ( "fmt" - "github.com/goccy/go-json/internal/encoder" + "github.com/bytedance/sonic/internal/encoder" ) func DebugRun(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]byte, error) { diff --git a/internal/encoder/vm_color_indent/util.go b/internal/encoder/vm_color_indent/util.go index 2395abec..c242d705 100644 --- a/internal/encoder/vm_color_indent/util.go +++ b/internal/encoder/vm_color_indent/util.go @@ -5,8 +5,8 @@ import ( "fmt" "unsafe" - "github.com/goccy/go-json/internal/encoder" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/encoder" + "github.com/bytedance/sonic/internal/runtime" ) const uintptrSize = 4 << (^uintptr(0) >> 63) diff --git a/internal/encoder/vm_color_indent/vm.go b/internal/encoder/vm_color_indent/vm.go index 3b4e22e5..76298925 100644 --- a/internal/encoder/vm_color_indent/vm.go +++ b/internal/encoder/vm_color_indent/vm.go @@ -7,8 +7,8 @@ import ( "sort" "unsafe" - "github.com/goccy/go-json/internal/encoder" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/encoder" + "github.com/bytedance/sonic/internal/runtime" ) func Run(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]byte, error) { diff --git a/internal/encoder/vm_indent/debug_vm.go b/internal/encoder/vm_indent/debug_vm.go index 99395388..a92abcfb 100644 --- a/internal/encoder/vm_indent/debug_vm.go +++ b/internal/encoder/vm_indent/debug_vm.go @@ -3,7 +3,7 @@ package vm_indent import ( "fmt" - "github.com/goccy/go-json/internal/encoder" + "github.com/bytedance/sonic/internal/encoder" ) func DebugRun(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]byte, error) { diff --git a/internal/encoder/vm_indent/hack.go b/internal/encoder/vm_indent/hack.go index 9e245bfe..1e4bf97e 100644 --- a/internal/encoder/vm_indent/hack.go +++ b/internal/encoder/vm_indent/hack.go @@ -5,5 +5,5 @@ import ( // `vm`, `vm_indent`, `vm_color`, `vm_color_indent` packages uses a lot of memory to compile, // so forcibly make dependencies and avoid compiling in concurrent. // dependency order: vm => vm_indent => vm_color => vm_color_indent - _ "github.com/goccy/go-json/internal/encoder/vm_color" + _ "github.com/bytedance/sonic/internal/encoder/vm_color" ) diff --git a/internal/encoder/vm_indent/util.go b/internal/encoder/vm_indent/util.go index 6cb745e3..4458117f 100644 --- a/internal/encoder/vm_indent/util.go +++ b/internal/encoder/vm_indent/util.go @@ -5,8 +5,8 @@ import ( "fmt" "unsafe" - "github.com/goccy/go-json/internal/encoder" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/encoder" + "github.com/bytedance/sonic/internal/runtime" ) const uintptrSize = 4 << (^uintptr(0) >> 63) diff --git a/internal/encoder/vm_indent/vm.go b/internal/encoder/vm_indent/vm.go index 836c5c8a..2fe38181 100644 --- a/internal/encoder/vm_indent/vm.go +++ b/internal/encoder/vm_indent/vm.go @@ -7,8 +7,8 @@ import ( "sort" "unsafe" - "github.com/goccy/go-json/internal/encoder" - "github.com/goccy/go-json/internal/runtime" + "github.com/bytedance/sonic/internal/encoder" + "github.com/bytedance/sonic/internal/runtime" ) func Run(ctx *encoder.RuntimeContext, b []byte, codeSet *encoder.OpcodeSet) ([]byte, error) { diff --git a/json.go b/json.go index fb18065a..eff31c9f 100644 --- a/json.go +++ b/json.go @@ -1,11 +1,11 @@ -package json +package sonic import ( "bytes" "context" "encoding/json" - "github.com/goccy/go-json/internal/encoder" + "github.com/bytedance/sonic/internal/encoder" ) // Marshaler is the interface implemented by types that diff --git a/json_test.go b/json_test.go index 869b7835..0ff52e6f 100644 --- a/json_test.go +++ b/json_test.go @@ -1,4 +1,4 @@ -package json_test +package sonic_test import ( "bytes" @@ -8,7 +8,7 @@ import ( "reflect" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) var validTests = []struct { diff --git a/number_test.go b/number_test.go index 4c5e3ef5..0f89076c 100644 --- a/number_test.go +++ b/number_test.go @@ -2,13 +2,13 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -package json_test +package sonic_test import ( "regexp" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestNumberIsValid(t *testing.T) { diff --git a/option.go b/option.go index 378031a0..12d2f45a 100644 --- a/option.go +++ b/option.go @@ -1,10 +1,10 @@ -package json +package sonic import ( "io" - "github.com/goccy/go-json/internal/decoder" - "github.com/goccy/go-json/internal/encoder" + "github.com/bytedance/sonic/internal/decoder" + "github.com/bytedance/sonic/internal/encoder" ) type EncodeOption = encoder.Option diff --git a/path.go b/path.go index 38abce78..4274f79e 100644 --- a/path.go +++ b/path.go @@ -1,9 +1,9 @@ -package json +package sonic import ( "reflect" - "github.com/goccy/go-json/internal/decoder" + "github.com/bytedance/sonic/internal/decoder" ) // CreatePath creates JSON Path. diff --git a/path_test.go b/path_test.go index 4891eb8f..0048e344 100644 --- a/path_test.go +++ b/path_test.go @@ -1,4 +1,4 @@ -package json_test +package sonic_test import ( "bytes" @@ -6,7 +6,7 @@ import ( "sort" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestExtractPath(t *testing.T) { diff --git a/query.go b/query.go index 4b11cf20..10822e8b 100644 --- a/query.go +++ b/query.go @@ -1,7 +1,7 @@ -package json +package sonic import ( - "github.com/goccy/go-json/internal/encoder" + "github.com/bytedance/sonic/internal/encoder" ) type ( diff --git a/query_test.go b/query_test.go index d8cac61d..7c88e373 100644 --- a/query_test.go +++ b/query_test.go @@ -1,11 +1,11 @@ -package json_test +package sonic_test import ( "context" "reflect" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type queryTestX struct { diff --git a/size_test.go b/size_test.go index 00c3a2b7..30b89450 100644 --- a/size_test.go +++ b/size_test.go @@ -1,10 +1,10 @@ -package json +package sonic import ( "testing" "unsafe" - "github.com/goccy/go-json/internal/encoder" + "github.com/bytedance/sonic/internal/encoder" ) func TestOpcodeSize(t *testing.T) { diff --git a/stream_test.go b/stream_test.go index 7b32df86..77bf6c83 100644 --- a/stream_test.go +++ b/stream_test.go @@ -2,11 +2,12 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -package json_test +package sonic_test import ( "bytes" "compress/gzip" + "encoding/json" "fmt" "io" "log" @@ -17,8 +18,6 @@ import ( "strconv" "strings" "testing" - - "github.com/goccy/go-json" ) // Test values for the stream test. diff --git a/tagkey_test.go b/tagkey_test.go index d6aacc40..486d0e41 100644 --- a/tagkey_test.go +++ b/tagkey_test.go @@ -2,12 +2,12 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -package json_test +package sonic_test import ( "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type basicLatin2xTag struct { diff --git a/test/cover/cover_array_test.go b/test/cover/cover_array_test.go index 16140786..420ea2c1 100644 --- a/test/cover/cover_array_test.go +++ b/test/cover/cover_array_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverArray(t *testing.T) { diff --git a/test/cover/cover_bool_test.go b/test/cover/cover_bool_test.go index 8dea1749..870de243 100644 --- a/test/cover/cover_bool_test.go +++ b/test/cover/cover_bool_test.go @@ -6,7 +6,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type customBool bool diff --git a/test/cover/cover_bytes_test.go b/test/cover/cover_bytes_test.go index 28ab9db8..e834cf29 100644 --- a/test/cover/cover_bytes_test.go +++ b/test/cover/cover_bytes_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverBytes(t *testing.T) { diff --git a/test/cover/cover_float32_test.go b/test/cover/cover_float32_test.go index 44fecdfd..508d959c 100644 --- a/test/cover/cover_float32_test.go +++ b/test/cover/cover_float32_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverFloat32(t *testing.T) { diff --git a/test/cover/cover_float64_test.go b/test/cover/cover_float64_test.go index c94644ec..cbc4ecb1 100644 --- a/test/cover/cover_float64_test.go +++ b/test/cover/cover_float64_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverFloat64(t *testing.T) { diff --git a/test/cover/cover_helper_test.go b/test/cover/cover_helper_test.go index 8dd9f977..b0d3f6f7 100644 --- a/test/cover/cover_helper_test.go +++ b/test/cover/cover_helper_test.go @@ -4,7 +4,7 @@ import ( "bytes" stdjson "encoding/json" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func intptr(v int) *int { return &v } diff --git a/test/cover/cover_int16_test.go b/test/cover/cover_int16_test.go index cc7867db..87a84f2f 100644 --- a/test/cover/cover_int16_test.go +++ b/test/cover/cover_int16_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverInt16(t *testing.T) { diff --git a/test/cover/cover_int32_test.go b/test/cover/cover_int32_test.go index 195301b9..9dcdc5fd 100644 --- a/test/cover/cover_int32_test.go +++ b/test/cover/cover_int32_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverInt32(t *testing.T) { diff --git a/test/cover/cover_int64_test.go b/test/cover/cover_int64_test.go index 612fa8e6..16f9ff96 100644 --- a/test/cover/cover_int64_test.go +++ b/test/cover/cover_int64_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverInt64(t *testing.T) { diff --git a/test/cover/cover_int8_test.go b/test/cover/cover_int8_test.go index b609e981..2831d09e 100644 --- a/test/cover/cover_int8_test.go +++ b/test/cover/cover_int8_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverInt8(t *testing.T) { diff --git a/test/cover/cover_int_test.go b/test/cover/cover_int_test.go index c2377d43..4b6807f6 100644 --- a/test/cover/cover_int_test.go +++ b/test/cover/cover_int_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverInt(t *testing.T) { diff --git a/test/cover/cover_map_test.go b/test/cover/cover_map_test.go index 0b9a5fe9..76c76a8d 100644 --- a/test/cover/cover_map_test.go +++ b/test/cover/cover_map_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type recursiveMap struct { diff --git a/test/cover/cover_marshal_json_test.go b/test/cover/cover_marshal_json_test.go index 95d92b89..10c4dccc 100644 --- a/test/cover/cover_marshal_json_test.go +++ b/test/cover/cover_marshal_json_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type coverMarshalJSON struct { diff --git a/test/cover/cover_marshal_text_test.go b/test/cover/cover_marshal_text_test.go index 9cee6d44..e7cf368a 100644 --- a/test/cover/cover_marshal_text_test.go +++ b/test/cover/cover_marshal_text_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type coverMarshalText struct { diff --git a/test/cover/cover_number_test.go b/test/cover/cover_number_test.go index 5b98a08d..841eba27 100644 --- a/test/cover/cover_number_test.go +++ b/test/cover/cover_number_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverNumber(t *testing.T) { diff --git a/test/cover/cover_slice_test.go b/test/cover/cover_slice_test.go index 70a03063..c1cdff29 100644 --- a/test/cover/cover_slice_test.go +++ b/test/cover/cover_slice_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type coverSliceMarshalJSON struct { diff --git a/test/cover/cover_string_test.go b/test/cover/cover_string_test.go index 41904e49..94749bea 100644 --- a/test/cover/cover_string_test.go +++ b/test/cover/cover_string_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverString(t *testing.T) { diff --git a/test/cover/cover_uint16_test.go b/test/cover/cover_uint16_test.go index 4514bb0b..7fdba65b 100644 --- a/test/cover/cover_uint16_test.go +++ b/test/cover/cover_uint16_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverUint16(t *testing.T) { diff --git a/test/cover/cover_uint32_test.go b/test/cover/cover_uint32_test.go index 8d852b98..39e63335 100644 --- a/test/cover/cover_uint32_test.go +++ b/test/cover/cover_uint32_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverUint32(t *testing.T) { diff --git a/test/cover/cover_uint64_test.go b/test/cover/cover_uint64_test.go index bc074ce8..2904278c 100644 --- a/test/cover/cover_uint64_test.go +++ b/test/cover/cover_uint64_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverUint64(t *testing.T) { diff --git a/test/cover/cover_uint8_test.go b/test/cover/cover_uint8_test.go index fab94031..bd4c6b75 100644 --- a/test/cover/cover_uint8_test.go +++ b/test/cover/cover_uint8_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverUint8(t *testing.T) { diff --git a/test/cover/cover_uint_test.go b/test/cover/cover_uint_test.go index e33064a1..65c283eb 100644 --- a/test/cover/cover_uint_test.go +++ b/test/cover/cover_uint_test.go @@ -5,7 +5,7 @@ import ( "fmt" "testing" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func TestCoverUint(t *testing.T) { diff --git a/test/example/example_marshaling_test.go b/test/example/example_marshaling_test.go index 0119ecc6..590a2171 100644 --- a/test/example/example_marshaling_test.go +++ b/test/example/example_marshaling_test.go @@ -9,7 +9,7 @@ import ( "log" "strings" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type Animal int diff --git a/test/example/example_query_test.go b/test/example/example_query_test.go index cca22ba3..acf1bec1 100644 --- a/test/example/example_query_test.go +++ b/test/example/example_query_test.go @@ -5,7 +5,7 @@ import ( "fmt" "log" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type User struct { diff --git a/test/example/example_test.go b/test/example/example_test.go index da65764a..5382c171 100644 --- a/test/example/example_test.go +++ b/test/example/example_test.go @@ -12,7 +12,7 @@ import ( "os" "strings" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) func ExampleMarshal() { diff --git a/test/example/example_text_marshaling_test.go b/test/example/example_text_marshaling_test.go index 090cd632..8296d4ec 100644 --- a/test/example/example_text_marshaling_test.go +++ b/test/example/example_text_marshaling_test.go @@ -9,7 +9,7 @@ import ( "log" "strings" - "github.com/goccy/go-json" + json "github.com/bytedance/sonic" ) type Size int