Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/tools/godoc: Use "IsPredeclared" of go/doc #20357

Closed
178inaba opened this issue May 13, 2017 · 5 comments
Closed

x/tools/godoc: Use "IsPredeclared" of go/doc #20357

178inaba opened this issue May 13, 2017 · 5 comments
Milestone

Comments

@178inaba
Copy link
Contributor

What version of Go are you using (go version)?

go version go1.8.1 darwin/amd64

What operating system and processor architecture are you using (go env)?

GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/Users/i178inaba/work/go"
GORACE=""
GOROOT="/usr/local/Cellar/go/1.8.1/libexec"
GOTOOLDIR="/usr/local/Cellar/go/1.8.1/libexec/pkg/tool/darwin_amd64"
GCCGO="gccgo"
CC="clang"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/8b/5j9t64vs0sg_n1jjfkkrg88m0000gn/T/go-build740177373=/tmp/go-build -gno-record-gcc-switches -fno-common"
CXX="clang++"
CGO_ENABLED="1"
PKG_CONFIG="pkg-config"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"

What did you do?

I saw the following comments.
https://github.com/golang/tools/blob/ce1291533bf047e29f9e188b3f697d3a5157d142/godoc/linkify.go#L196

// The predeclared map represents the set of all predeclared identifiers.
// TODO(gri) This information is also encoded in similar maps in go/doc,
//           but not exported. Consider exporting an accessor and using
//           it instead.
var predeclared = map[string]bool{

I knew that there was a function called "IsPredeclared" in go/doc.
Fixed it to use it.

What did you expect to see?

None.

What did you see instead?

None.

@gopherbot gopherbot added this to the Unreleased milestone May 13, 2017
@gopherbot
Copy link

CL https://golang.org/cl/43473 mentions this issue.

@bradfitz
Copy link
Contributor

I'll reopen this, but it can't really be fixed until Go 1.10 probably.

@bradfitz bradfitz reopened this May 15, 2017
@bradfitz bradfitz modified the milestones: Go1.10, Unreleased May 15, 2017
@178inaba
Copy link
Contributor Author

I would like to continue to take charge of this issue.

@178inaba
Copy link
Contributor Author

I have sent change again because go1.9 was released.
https://go-review.googlesource.com/c/tools/+/58890

@gopherbot
Copy link

Change https://golang.org/cl/58890 mentions this issue: godoc: use "IsPredeclared" of go/doc

@golang golang locked and limited conversation to collaborators Nov 15, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants