diff options
Diffstat (limited to 'src/encoding')
| -rw-r--r-- | src/encoding/csv/fuzz.go | 14 | ||||
| -rw-r--r-- | src/encoding/gob/codec_test.go | 2 | ||||
| -rw-r--r-- | src/encoding/json/encode_test.go | 4 |
3 files changed, 10 insertions, 10 deletions
diff --git a/src/encoding/csv/fuzz.go b/src/encoding/csv/fuzz.go index dc33893dd7..8be21d5d28 100644 --- a/src/encoding/csv/fuzz.go +++ b/src/encoding/csv/fuzz.go @@ -17,13 +17,13 @@ func Fuzz(data []byte) int { buf := new(bytes.Buffer) for _, tt := range []Reader{ - Reader{}, - Reader{Comma: ';'}, - Reader{Comma: '\t'}, - Reader{LazyQuotes: true}, - Reader{TrimLeadingSpace: true}, - Reader{Comment: '#'}, - Reader{Comment: ';'}, + {}, + {Comma: ';'}, + {Comma: '\t'}, + {LazyQuotes: true}, + {TrimLeadingSpace: true}, + {Comment: '#'}, + {Comment: ';'}, } { r := NewReader(bytes.NewReader(data)) r.Comma = tt.Comma diff --git a/src/encoding/gob/codec_test.go b/src/encoding/gob/codec_test.go index 494abc9b91..f38e88b638 100644 --- a/src/encoding/gob/codec_test.go +++ b/src/encoding/gob/codec_test.go @@ -591,7 +591,7 @@ func TestEndToEnd(t *testing.T) { B: 18, C: -5, M: map[string]*float64{"pi": &pi, "e": &e}, - M2: map[int]T3{4: T3{X: pi, Z: &meaning}, 10: T3{X: e, Z: &fingers}}, + M2: map[int]T3{4: {X: pi, Z: &meaning}, 10: {X: e, Z: &fingers}}, Mstring: map[string]string{"pi": "3.14", "e": "2.71"}, Mintptr: map[int]*int{meaning: &fingers, fingers: &meaning}, Mcomp: map[complex128]complex128{comp1: comp2, comp2: comp1}, diff --git a/src/encoding/json/encode_test.go b/src/encoding/json/encode_test.go index 642f397fb9..daab713766 100644 --- a/src/encoding/json/encode_test.go +++ b/src/encoding/json/encode_test.go @@ -796,8 +796,8 @@ func TestTextMarshalerMapKeysAreSorted(t *testing.T) { // https://golang.org/issue/33675 func TestNilMarshalerTextMapKey(t *testing.T) { b, err := Marshal(map[*unmarshalerText]int{ - (*unmarshalerText)(nil): 1, - &unmarshalerText{"A", "B"}: 2, + (*unmarshalerText)(nil): 1, + {"A", "B"}: 2, }) if err != nil { t.Fatalf("Failed to Marshal *text.Marshaler: %v", err) |
