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/gopls: improve error messages for interface implementation diagnostics #39062

Open
stamblerre opened this issue May 14, 2020 · 0 comments
Open
Labels
Milestone

Comments

@stamblerre
Copy link
Contributor

@stamblerre stamblerre commented May 14, 2020

See the example in https://play.golang.org/p/2TrSYmBsdLU.

In this case, both the compiler and go/types report error messages on L17 where the error occurs. However, in cases like these, the user is most likely interested in fixing their mistake on L9 by changing the return type of Hello. We should add this position in the RelatedInformation field of diagnostics.

@stamblerre stamblerre added this to the gopls/v0.5.0 milestone May 14, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.