From 2184a394777ccc9ce9625932b2ad773e6e626be0 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Olivier=20Mengu=C3=A9?= Date: Thu, 14 Dec 2023 18:25:21 +0100 Subject: [PATCH] runtime/metrics: godoc link fixes MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Fix rendering of link to runtime/debug.ReadGCStats in package overview: as the package is not imported we must specify the absolute package name. Change-Id: I123db49eee05e6812427e19873e628b4e4feb203 Reviewed-on: https://go-review.googlesource.com/c/go/+/549735 Reviewed-by: Than McIntosh Reviewed-by: Daniel Martí Auto-Submit: Michael Knyszek TryBot-Result: Gopher Robot Reviewed-by: Michael Knyszek Run-TryBot: qiulaidongfeng <2645477756@qq.com> Reviewed-by: qiulaidongfeng <2645477756@qq.com> --- src/runtime/metrics/doc.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/runtime/metrics/doc.go b/src/runtime/metrics/doc.go index e5a1fbc8d2..fb2f44da29 100644 --- a/src/runtime/metrics/doc.go +++ b/src/runtime/metrics/doc.go @@ -8,7 +8,7 @@ /* Package metrics provides a stable interface to access implementation-defined metrics exported by the Go runtime. This package is similar to existing functions -like [runtime.ReadMemStats] and [debug.ReadGCStats], but significantly more general. +like [runtime.ReadMemStats] and [runtime/debug.ReadGCStats], but significantly more general. The set of metrics defined by this package may evolve as the runtime itself evolves, and also enables variation across Go implementations, whose relevant @@ -28,7 +28,8 @@ encouraged to use build tags, and although metrics may be deprecated and removed users should consider this to be an exceptional and rare event, coinciding with a very large change in a particular Go implementation. -Each metric key also has a "kind" that describes the format of the metric's value. +Each metric key also has a "kind" (see [ValueKind]) that describes the format of the +metric's value. In the interest of not breaking users of this package, the "kind" for a given metric is guaranteed not to change. If it must change, then a new metric will be introduced with a new key and a new "kind." -- 2.48.1