mirror of
https://github.com/golang/go
synced 2024-11-24 09:00:13 -07:00
cmd/go/internal/work: omit modinfo line from cache key when empty
Cache keys are dumped in case of mismatch; an empty modinfo string adds noise to that dump without a corresponding benefit. For #52009. Change-Id: I1b4cd85fa5ff920973552fc94977954f93622a32 Reviewed-on: https://go-review.googlesource.com/c/go/+/398059 Trust: Bryan Mills <bcmills@google.com> Run-TryBot: Bryan Mills <bcmills@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
parent
62bceae32d
commit
592078ff3f
@ -303,7 +303,9 @@ func (b *Builder) buildActionID(a *Action) cache.ActionID {
|
||||
fmt.Fprintf(h, "fuzz %q\n", fuzzFlags)
|
||||
}
|
||||
}
|
||||
fmt.Fprintf(h, "modinfo %q\n", p.Internal.BuildInfo)
|
||||
if p.Internal.BuildInfo != "" {
|
||||
fmt.Fprintf(h, "modinfo %q\n", p.Internal.BuildInfo)
|
||||
}
|
||||
|
||||
// Configuration specific to compiler toolchain.
|
||||
switch cfg.BuildToolchainName {
|
||||
|
Loading…
Reference in New Issue
Block a user