-
Notifications
You must be signed in to change notification settings - Fork 646
"Go to Definition" not working for structs #459
Comments
Correction, it seems this feature does work, but only for functions and not |
@lukehoban @zmb3 @abarisain Would integrating |
I think so ! |
Actually, it already works on my gogetdoc2 branch. @apkrieg if you can do a small repro file that fails with the current version, I could confirm that gogetdoc fills this gap |
@abarisain I tried it with three libraries:
The only library I can use "Go to Definition" with is
|
Thanks for the repro, I got the same results on my windows computer on the master branch. While it is a little slower than godef, the abarisain/vscode-go gogetdoc2 branch handles this correctly. |
The current implementation fails mostly because of these few lines: https://github.com/Microsoft/vscode-go/blob/8c7d2d364059d4ed30d8931476306c6b9ef011bc/src/goDeclaration.ts#L66-L70 From what I can tell, it looks for |
Is this still a problem? I tried the example at https://gobyexample.com/interfaces which uses structs and interfaces. I was able to use the I am running VS Code 1.6.1 with Go extension 0.6.45 in Mac OS X |
In the latest update of the Go extension (0.6.50), we now support the use of |
This is a feature my colleagues and I use very often when programming in Go (and other languages). I'm not sure if this is already implemented and I have not enabled it or if it is simply missing.
The text was updated successfully, but these errors were encountered: