Skip to content
This repository has been archived by the owner on Apr 13, 2020. It is now read-only.

Consider using native go tool when resolving locations #4

Open
mokiat opened this issue Sep 26, 2018 · 1 comment
Open

Consider using native go tool when resolving locations #4

mokiat opened this issue Sep 26, 2018 · 1 comment

Comments

@mokiat
Copy link
Owner

mokiat commented Sep 26, 2018

It seems that this is the preferred approach when dealing with go files / packages / locations, as can be seen discussed in the following issue:
golang/go#26504

It needs to be checked whether the go tool provides commands for all resolutions we make in the code.

Potential implications:

  • The performance might drop a bit
  • The tool will need to parse and rely on go output
  • The go tool would need to be present on PATH (though would anyone ever use gostub if they haven't set up their go environment?)
@mokiat
Copy link
Owner Author

mokiat commented Sep 26, 2018

P.S. An alternative is to migrate to the following package:
https://godoc.org/golang.org/x/tools/go/packages

This has already been done partially on the bump_go_11 branch:
https://github.com/mokiat/gostub/tree/bump_go_11

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant