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

Auto-complete in documentation string #3495

Open
varfigstar opened this issue Aug 17, 2024 · 4 comments
Open

Auto-complete in documentation string #3495

varfigstar opened this issue Aug 17, 2024 · 4 comments
Labels
FeatureRequest WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.
Milestone

Comments

@varfigstar
Copy link

Problem
I saw in https://go.dev/blog/godoc that there is a simple convention about documentation in golang:
you should to write object's name firstly and then describe it's functionality.

Soulution
What about to add auto-complete in object's documentations to avoid manually retyping it's name?

@gopherbot gopherbot added this to the Untriaged milestone Aug 17, 2024
@hyangah
Copy link
Contributor

hyangah commented Aug 19, 2024

The extension already provides the name as the first candidate of the completion results if you trigger completion after // . Is it not working for you? If so, please share the repro case so we can triage.

@hyangah hyangah added FeatureRequest WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided. and removed Documentation labels Aug 19, 2024
@varfigstar
Copy link
Author

varfigstar commented Aug 20, 2024

No, it's not working for me.
image

Also, nothing in extension logs.

Regular autocomplete is working.

@hyangah
Copy link
Contributor

hyangah commented Aug 20, 2024

Can you please follow the step here
https://github.com/golang/vscode-go/wiki/troubleshooting#collect-extension-logs

and share the log if sharing the repro case is not possible?

We also need gopls and go versions, and your editor settings.

@varfigstar
Copy link
Author

varfigstar commented Aug 22, 2024

My representation case is simple: i have method named FromDB. When i try to make doc string for this method - there are no completion suggestions. And it also doesn't work for any other method, function, struct field...

My go version is 1.22.5
My golps version is golang.org/x/tools/gopls v0.16.1

My logs from golps after typing // Fr

logs.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FeatureRequest WaitingForInfo Issue is not actionable because of missing required information, which needs to be provided.
Projects
None yet
Development

No branches or pull requests

3 participants