1
0
mirror of https://github.com/golang/go synced 2024-11-24 18:20:02 -07:00
go/doc
Brad Fitzpatrick 351c15f1ce all: remove public named return values when useless
Named returned values should only be used on public funcs and methods
when it contributes to the documentation.

Named return values should not be used if they're only saving the
programmer a few lines of code inside the body of the function,
especially if that means there's stutter in the documentation or it
was only there so the programmer could use a naked return
statement. (Naked returns should not be used except in very small
functions)

This change is a manual audit & cleanup of public func signatures.

Signatures were not changed if:

* the func was private (wouldn't be in public godoc)
* the documentation referenced it
* the named return value was an interesting name. (i.e. it wasn't
  simply stutter, repeating the name of the type)

There should be no changes in behavior. (At least: none intended)

Change-Id: I3472ef49619678fe786e5e0994bdf2d9de76d109
Reviewed-on: https://go-review.googlesource.com/20024
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Gerrand <adg@golang.org>
2016-02-29 03:31:19 +00:00
..
articles
codewalk doc: rewrite references to plan9.bell-labs.com to 9p.io 2016-02-04 22:47:16 +00:00
devel doc: fix typo in go1.6 release date. 2016-02-17 23:13:51 +00:00
gopher all: link to https for golang subdomains too 2015-07-12 04:42:40 +00:00
play doc/play: update URL for concurrent pi 2016-01-06 20:23:21 +00:00
progs all: remove executable bit from several files 2015-09-04 02:59:49 +00:00
asm.html doc: fix remaining TODOs in Go 1.6 release notes 2016-02-16 16:46:17 +00:00
cmd.html
code.html doc: add Overview and other small edits to How To Write Go Code 2016-01-12 01:56:04 +00:00
conduct.html doc: Americanise spelling of wilful 2015-12-17 21:32:59 +00:00
contrib.html doc: add Code of Conduct 2015-11-24 04:07:58 +00:00
contribute.html doc: mention multi-change branches in contribute.html 2016-02-17 18:23:12 +00:00
debugging_with_gdb.html doc: fix source link in gdb docs 2016-01-06 21:58:19 +00:00
docs.html
effective_go.html all: remove public named return values when useless 2016-02-29 03:31:19 +00:00
gccgo_contribute.html
gccgo_install.html all: link to https instead of http 2015-07-11 14:36:33 +00:00
go1.1.html
go1.2.html
go1.3.html
go1.4.html
go1.5.html doc: mention that go install removes binaries built by go build 2015-09-08 18:46:07 +00:00
go1.6.html doc: remove DRAFT tags from go1.6.html 2016-02-17 18:25:10 +00:00
go1.7.txt doc: go1.7.txt updates 2016-02-27 01:23:21 +00:00
go1.html
go1compat.html doc: add a clause about embedded methods to go1compat 2015-07-22 01:25:32 +00:00
go_faq.html doc: rewrite references to plan9.bell-labs.com to 9p.io 2016-02-04 22:47:16 +00:00
go_mem.html
go_spec.html spec: fix EBNF for slice syntax 2016-02-23 19:18:25 +00:00
go-logo-black.png
go-logo-blue.png
go-logo-white.png
help.html doc: revise help page with categories and more links 2016-01-14 03:15:39 +00:00
ie.css
install-source.html doc: add android/arm as a valid GOOS/GOARCH combination 2016-02-25 00:38:16 +00:00
install.html doc: remove note about installing from source for ARM 2016-01-07 04:12:01 +00:00
root.html doc: only show Share button when enabled 2015-09-02 05:58:52 +00:00
security.html doc: add Go Security Policy document 2015-09-03 03:02:17 +00:00
share.png
tos.html