Skip to content

Commit

Permalink
cmd/go/internal/module: document Version usage for filesystem replace…
Browse files Browse the repository at this point in the history
…ments

Updates #34085

Change-Id: I57250d0c51a27f0bd3e223588dde9d6d955e0fcf
Reviewed-on: https://go-review.googlesource.com/c/go/+/193618
Run-TryBot: Bryan C. Mills <[email protected]>
TryBot-Result: Gobot Gobot <[email protected]>
Reviewed-by: Jay Conrod <[email protected]>
  • Loading branch information
Bryan C. Mills committed Sep 10, 2019
1 parent 0a3b65c commit 5bb19e3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/cmd/go/internal/module/module.go
Original file line number Diff line number Diff line change
Expand Up @@ -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"`
}

Expand Down

0 comments on commit 5bb19e3

Please sign in to comment.