]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/pprof/internal: map/slice literals janitoring
authorDidier Spezia <didier.06@gmail.com>
Sun, 23 Aug 2015 12:41:07 +0000 (12:41 +0000)
committerRuss Cox <rsc@golang.org>
Sat, 5 Dec 2015 04:01:28 +0000 (04:01 +0000)
Simplify slice/map literal expression.
Caught with gofmt -d -s, fixed with gofmt -w -s

Change-Id: I19723900d0649019bf79b9330d68525a68ed69c4
Reviewed-on: https://go-review.googlesource.com/13835
Reviewed-by: Russ Cox <rsc@golang.org>
src/cmd/pprof/internal/profile/legacy_profile.go

index e4c92cdd1969d22f488bcdc0ae2424dcbaa0edef..c7c047a64b38ca9255f235751483f78999a6163d 100644 (file)
@@ -589,7 +589,7 @@ func parseHeap(b []byte) (p *Profile, err error) {
                p.Sample = append(p.Sample, &Sample{
                        Value:    value,
                        Location: sloc,
-                       NumLabel: map[string][]int64{"bytes": []int64{blocksize}},
+                       NumLabel: map[string][]int64{"bytes": {blocksize}},
                })
        }