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/pkgsite: support showing identifiers that are constrained by build tags #45833

Closed
codyoss opened this issue Apr 28, 2021 · 4 comments
Closed

Comments

@codyoss
Copy link
Member

codyoss commented Apr 28, 2021

What did you do?

What did you expect to see?

I expect some way to view docs for identifiers that are guarded by build constraints and the file to be listed is source files. Maybe something similar to how the official language docs can call out what version of Go an identifier was added in or a dropdown to select constraints? This could also be useful if a Windows version of a function has slightly different docs than the linux version.

What did you see instead?

I could not view the docs for my constrained function. Nor could I see constrained.go in the list of Source Files.

Additional context

This is sort of an off-shoot of some of the chatter in #34409. A suggestion was made to hide identifiers with build constraints. To me this would only be viable if developers could see those identifiers in documentation easily.

@gopherbot gopherbot added this to the Proposal milestone Apr 28, 2021
@ianlancetaylor ianlancetaylor added this to Incoming in Proposals (old) Apr 28, 2021
@ianlancetaylor
Copy link
Contributor

CC @julieqiu

@julieqiu
Copy link
Member

We do support a few common build tags for GOOS/GOARCH, but not arbitrary tags. This was discussed in #37232.

@rsc
Copy link
Contributor

rsc commented May 12, 2021

The proposal process is for "any notable change or addition to the language, libraries and tools", largely because once we ship them, we can't take them back. We have to make sure we get to things we are comfortable with for at least the next decade or so.

This isn't true of pkgsite, so pkgsite issues need not be in the proposal process.

Spoke to @julieqiu about this one and she said that GOOS/GOARCH are handled and that probably arbitrary build tags are too much work for too little benefit, but I will leave it to her to close.

Removing from proposal bins.

@rsc rsc changed the title proposal: x/pkgsite: support showing identifiers that are constrained by build tags x/pkgsite: support showing identifiers that are constrained by build tags May 12, 2021
@rsc rsc removed this from Incoming in Proposals (old) May 12, 2021
@rsc rsc removed the Proposal label May 12, 2021
@rsc rsc modified the milestones: Proposal, Unreleased May 12, 2021
@jba
Copy link
Contributor

jba commented May 18, 2021

Going to close this. Reopen if there is something new here not covered in #37232.

@jba jba closed this as completed May 18, 2021
@golang golang locked and limited conversation to collaborators May 18, 2022
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

6 participants