diff --git a/src/encoding/json/example_test.go b/src/encoding/json/example_test.go index 2088c34297..fbecf1b593 100644 --- a/src/encoding/json/example_test.go +++ b/src/encoding/json/example_test.go @@ -279,12 +279,12 @@ func ExampleMarshalIndent() { "b": 2, } - json, err := json.MarshalIndent(data, "", "") + b, err := json.MarshalIndent(data, "", "") if err != nil { log.Fatal(err) } - fmt.Println(string(json)) + fmt.Println(string(b)) // Output: // { // "a": 1,