This is a second attempt at CL 230024, with
cmd/go/testdata/script/mod_retention.txt updated to perform a
version-independent comparison on the 'go' version added to a go.mod
file that lacks one.
Fixes #38708
Change-Id: I15dcd83b51ed5ec57946b419bcbaec41e85a46f9
Reviewed-on: https://go-review.googlesource.com/c/go/+/230382
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
# However, that should not remove other redundant requirements.
cp go.mod.nogo go.mod
go list all
-cmp go.mod go.mod.redundant
+cmpenv go.mod go.mod.currentgo
-- go.mod.tidy --
rsc.io/sampler v1.3.0 // indirect
rsc.io/testonly v1.0.0 // indirect
)
+-- go.mod.currentgo --
+module m
+
+go $goversion
+
+require (
+ rsc.io/quote v1.5.2
+ rsc.io/sampler v1.3.0 // indirect
+ rsc.io/testonly v1.0.0 // indirect
+)
// - "go1.12", from Go version 1.12 onward
// - "go1.13", from Go version 1.13 onward
// - "go1.14", from Go version 1.14 onward
+// - "go1.15", from Go version 1.15 onward
// - any additional words listed in ctxt.BuildTags
//
// There are no build tags for beta or minor releases.
//
// When incrementing this, also add to the list at src/go/build/doc.go
// (search for "onward").
-const Version = 14
+const Version = 15