]> Cypherpunks repositories - gostls13.git/commitdiff
doc/go1.22: document that reflect.PtrTo is deprecated
authorCherry Mui <cherryyz@google.com>
Fri, 8 Dec 2023 20:33:14 +0000 (15:33 -0500)
committerCherry Mui <cherryyz@google.com>
Fri, 8 Dec 2023 21:00:53 +0000 (21:00 +0000)
Updates #59599.
For #61422.

Change-Id: I923be38b719a78dd983372acad93f710a53b0922
Reviewed-on: https://go-review.googlesource.com/c/go/+/548036
Reviewed-by: Keith Randall <khr@google.com>
TryBot-Bypass: Cherry Mui <cherryyz@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
doc/go1.22.html

index fc0d95510fc9542f61e4e542bcdd2d351fccb528..c87d9d3b21e34598b71d0fd004cfd383d702d5a2 100644 (file)
@@ -633,6 +633,12 @@ defer func() {
       a value to zero using the language <code>==</code> operator.
     </p>
   </dd>
+  <dd>
+    <p><!-- https://go.dev/issue/59599, CL 511035 -->
+      The <a href="/pkg/reflect/#PtrTo"><code>PtrTo</code></a> function is deprecated,
+      in favor of <a href="/pkg/reflect/#PointerTo"><code>PointerTo</code></a>.
+    </p>
+  </dd>
 </dl><!-- reflect -->
 
 <dl id="runtime/metrics"><dt><a href="/pkg/runtime/metrics/">runtime/metrics</a></dt>