]> Cypherpunks repositories - gostls13.git/commit
cmd/internal/gc, cmd/internal/obj: clean up string returns
authorJosh Bleecher Snyder <josharian@gmail.com>
Fri, 27 Feb 2015 22:44:15 +0000 (22:44 +0000)
committerJosh Bleecher Snyder <josharian@gmail.com>
Fri, 27 Feb 2015 23:36:29 +0000 (23:36 +0000)
commit5f55011aeaa221407430503a09b1ee3fe020a679
tree3a476e518f396a5a21ecc6aedaf554cf1ea177f7
parentc2025c4131a62bc034c663d2e8c22e37b09fce04
cmd/internal/gc, cmd/internal/obj: clean up string returns

An artifact of the c2go translation was
a handful of instances of code like:

var s string
s += "foo"
return s

This CL converts those to simply 'return "foo"'.

The conversion was done mechanically with the
quick-and-dirty cleanup script at
https://gist.github.com/josharian/1fa4408044c163983e62.

I then manually moved a couple of comments in fmt.go.

toolstash -cmp thinks that there are no functional changes.

Change-Id: Ic0ebdd10f0fb8de0360a1041ce5cd10ae1168be9
Reviewed-on: https://go-review.googlesource.com/6265
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/cmd/internal/gc/fmt.go
src/cmd/internal/gc/mparith1.go
src/cmd/internal/obj/i386/list8.go
src/cmd/internal/obj/x86/list6.go