aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/go/internal/modload/buildlist.go
diff options
context:
space:
mode:
authorMichael Matloob <matloob@golang.org>2021-08-23 14:51:39 -0400
committerMichael Matloob <matloob@golang.org>2021-08-25 17:02:15 +0000
commit3b523caf4145c2d915c5ead69440f9b890634587 (patch)
treefadef9dc5f2ac9f593aab85b73dbe1aa87a9a610 /src/cmd/go/internal/modload/buildlist.go
parent109c13b64f815230af65af5c21e67cd7baa62a05 (diff)
downloadgo-3b523caf4145c2d915c5ead69440f9b890634587.tar.gz
go-3b523caf4145c2d915c5ead69440f9b890634587.zip
[dev.cmdgo] cmd/go: clean up TODOWorkspaces instances
Address some of the easier todos to address and remove the todos that have already been done and redundant todos. For #45713 Change-Id: I3fe4393168b10c6e005325258d9701713c92e9e4 Reviewed-on: https://go-review.googlesource.com/c/go/+/344491 Trust: Michael Matloob <matloob@golang.org> Run-TryBot: Michael Matloob <matloob@golang.org> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Jay Conrod <jayconrod@google.com>
Diffstat (limited to 'src/cmd/go/internal/modload/buildlist.go')
-rw-r--r--src/cmd/go/internal/modload/buildlist.go8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/cmd/go/internal/modload/buildlist.go b/src/cmd/go/internal/modload/buildlist.go
index 9989bb5b2a..14379b4c3c 100644
--- a/src/cmd/go/internal/modload/buildlist.go
+++ b/src/cmd/go/internal/modload/buildlist.go
@@ -139,7 +139,7 @@ func (rs *Requirements) initVendor(vendorList []module.Version) {
}
if MainModules.Len() != 1 {
- panic("There should be exactly one main moudle in Vendor mode.")
+ panic("There should be exactly one main module in Vendor mode.")
}
mainModule := MainModules.Versions()[0]
@@ -284,8 +284,10 @@ func readModGraph(ctx context.Context, depth modDepth, roots []module.Version) (
)
for _, m := range MainModules.Versions() {
// Require all roots from all main modules.
- _ = TODOWorkspaces("This isn't the correct behavior. " +
- "Fix this when the requirements struct is updated to reflect the struct of the module graph.")
+ _ = TODOWorkspaces("This flattens a level of the module graph, adding the dependencies " +
+ "of all main modules to a single requirements struct, and losing the information of which " +
+ "main module required which requirement. Rework the requirements struct and change this" +
+ "to reflect the structure of the main modules.")
mg.g.Require(m, roots)
}