]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/go/internal/module: document Version usage for filesystem replacements
authorBryan C. Mills <bcmills@google.com>
Thu, 5 Sep 2019 16:47:07 +0000 (12:47 -0400)
committerBryan C. Mills <bcmills@google.com>
Tue, 10 Sep 2019 19:03:09 +0000 (19:03 +0000)
Updates #34085

Change-Id: I57250d0c51a27f0bd3e223588dde9d6d955e0fcf
Reviewed-on: https://go-review.googlesource.com/c/go/+/193618
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Jay Conrod <jayconrod@google.com>
src/cmd/go/internal/module/module.go

index 3e0baba15b3ec81a2ed681a4daf35aa5ed3f9dce..a1a3ccfe8ac4b90885b229050190d626956d12ce 100644 (file)
@@ -33,11 +33,13 @@ type Version struct {
        Path string
 
        // Version is usually a semantic version in canonical form.
-       // There are two exceptions to this general rule.
+       // There are three exceptions to this general rule.
        // First, the top-level target of a build has no specific version
        // and uses Version = "".
        // Second, during MVS calculations the version "none" is used
        // to represent the decision to take no version of a given module.
+       // Third, filesystem paths found in "replace" directives are
+       // represented by a path with an empty version.
        Version string `json:",omitempty"`
 }