internal/goexperiment: fix godoc formatting

In internal/goexperiment fix godoc formatting (list indent, add godoc
links).

In internal/buildcfg fix godoc for Experiment.baseline.

Change-Id: I30eaba60cbf3978a375b50dda19dbb2830903bdb
Reviewed-on: https://go-review.googlesource.com/c/go/+/595915
Reviewed-by: Austin Clements <austin@google.com>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
Auto-Submit: Austin Clements <austin@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
This commit is contained in:
Olivier Mengué
2024-07-01 00:49:11 +02:00
committed by Gopher Robot
parent 740857f529
commit fdd7713fe5
2 changed files with 12 additions and 12 deletions

View File

@@ -25,7 +25,7 @@ type ExperimentFlags struct {
// (This is not necessarily the set of experiments the compiler itself
// was built with.)
//
// experimentBaseline specifies the experiment flags that are enabled by
// Experiment.baseline specifies the experiment flags that are enabled by
// default in the current toolchain. This is, in effect, the "control"
// configuration and any variation from this is an experiment.
var Experiment ExperimentFlags = func() ExperimentFlags {
@@ -54,7 +54,7 @@ var FramePointerEnabled = GOARCH == "amd64" || GOARCH == "arm64"
// configuration tuple and returns the enabled and baseline experiment
// flag sets.
//
// TODO(mdempsky): Move to internal/goexperiment.
// TODO(mdempsky): Move to [internal/goexperiment].
func ParseGOEXPERIMENT(goos, goarch, goexp string) (*ExperimentFlags, error) {
// regabiSupported is set to true on platforms where register ABI is
// supported and enabled by default.

View File

@@ -26,20 +26,20 @@
// In the toolchain, the set of experiments enabled for the current
// build should be accessed via objabi.Experiment.
//
// The set of experiments is included in the output of runtime.Version()
// The set of experiments is included in the output of [runtime.Version]()
// and "go version <binary>" if it differs from the default experiments.
//
// For the set of experiments supported by the current toolchain, see
// "go doc goexperiment.Flags".
//
// Note that this package defines the set of experiments (in Flags)
// Note that this package defines the set of experiments (in [Flags])
// and records the experiments that were enabled when the package
// was compiled (as boolean and integer constants).
//
// Note especially that this package does not itself change behavior
// at run time based on the GOEXPERIMENT variable.
// The code used in builds to interpret the GOEXPERIMENT variable
// is in the separate package internal/buildcfg.
// is in the separate package [internal/buildcfg].
package goexperiment
//go:generate go run mkconsts.go
@@ -51,7 +51,7 @@ package goexperiment
// tags, experiments use the strings.ToLower of their field name.
//
// For the baseline experimental configuration, see
// [internal/buildcfg.ParseGOEXPERIMENT].
// [internal/buildcfg.Experiment].
//
// If you change this struct definition, run "go generate".
type Flags struct {