]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/internal/objabi: remove -V=goexperiment internal special case
authorDmitri Shuralyov <dmitshur@golang.org>
Fri, 14 Nov 2025 18:00:28 +0000 (13:00 -0500)
committerGopher Robot <gobot@golang.org>
Fri, 21 Nov 2025 19:30:29 +0000 (11:30 -0800)
This special case was added in CL 310171 for test/run.go use, as the
comment still says, but run.go (cmd/internal/testdir/testdir_test.go
by now) stopped using this in CL 310732. There don't seem to be any
other internal or external uses of this special case, so delete it.

Doing this kind of a cleanup can become harder as more time passes,
so try it as early as now and see how it goes.

Change-Id: Ib52aac51ef05166f7349cfc7d63b860a8ece7ec0
Cq-Include-Trybots: luci.golang.try:gotip-linux-amd64-longtest
Reviewed-on: https://go-review.googlesource.com/c/go/+/720620
Auto-Submit: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Reviewed-by: Michael Matloob <matloob@google.com>
Reviewed-by: Michael Matloob <matloob@golang.org>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>

src/cmd/internal/objabi/flag.go

index 32d71d05751dd6599ee4a1a4f6fd7d64c9be6ce1..603bf8746c3f01922944010df27a6d2247f5f372 100644 (file)
@@ -95,16 +95,10 @@ func (versionFlag) Set(s string) error {
 
        p := ""
 
-       if s == "goexperiment" {
-               // test/run.go uses this to discover the full set of
-               // experiment tags. Report everything.
-               p = " X:" + strings.Join(buildcfg.Experiment.All(), ",")
-       } else {
-               // If the enabled experiments differ from the baseline,
-               // include that difference.
-               if goexperiment := buildcfg.Experiment.String(); goexperiment != "" {
-                       p = " X:" + goexperiment
-               }
+       // If the enabled experiments differ from the baseline,
+       // include that difference.
+       if goexperiment := buildcfg.Experiment.String(); goexperiment != "" {
+               p = " X:" + goexperiment
        }
 
        // The go command invokes -V=full to get a unique identifier