mirror of
https://github.com/golang/go
synced 2024-11-18 13:44:48 -07:00
1745ac5bc6
This change separates out different functions of mod handles. Previously, we had ModHandle and ModTidyHandle. ModHandle was used to parse go.mod files and get the results of `go mod why` and possible dependency upgrades. Now, we factor this out into 4 handles: ParseModHandle, ModWhyHandle, ModUpgradeHandle, and ModTidyHandle. This allows each handle to be specific to its own functionality. It also simplifies the code a bit, as the handles can be written in terms of ParseModHandles instead of FileHandles. I may have some follow-up CLs to refactor the `go mod tidy` logic out of the cache package, though I'm no longer certain that that's a good choice. Change-Id: I8e12299dfdda7bb61b05903d9aa474461d7f4836 Reviewed-on: https://go-review.googlesource.com/c/tools/+/239117 Run-TryBot: Rebecca Stambler <rstambler@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Heschi Kreinick <heschi@google.com> |
||
---|---|---|
.. | ||
testdata/unchanged | ||
code_lens.go | ||
diagnostics.go | ||
format.go | ||
hover.go | ||
mod_test.go |