From c2bb350d80fa6116094f819f48d83f1f34993295 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Fri, 26 May 2023 14:25:45 -0700 Subject: [PATCH] doc/go1.21: mention changes to the reflect package Added Value.Clear, deprecated SliceHeader and StringHeader. For #55002 For #56906 Change-Id: Ib7497aff830d56fad90c31ec28596e71a448e9ce Reviewed-on: https://go-review.googlesource.com/c/go/+/498757 Reviewed-by: Ian Lance Taylor Auto-Submit: Ian Lance Taylor Run-TryBot: Ian Lance Taylor Reviewed-by: Eli Bendersky Run-TryBot: Ian Lance Taylor TryBot-Result: Gopher Robot --- doc/go1.21.html | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/doc/go1.21.html b/doc/go1.21.html index b959cdb116..88200bf33e 100644 --- a/doc/go1.21.html +++ b/doc/go1.21.html @@ -652,15 +652,21 @@ Do not send CLs removing the interior tags from such phrases.

- TODO: https://go.dev/issue/55002: add Value.Clear -

- -

- TODO: https://go.dev/issue/56906: deprecate SliceHeader and StringHeader -

- -

- TODO: https://go.dev/cl/452762: reflect: deprecate SliceHeader and StringHeader; modified api/next/56906.txt + The new Value + method Value.Clear + clears the contents of a map or zeros the contents of a slice. + This corresponds to the new clear built-in + added to the language. +

+ +

+ The SliceHeader + and StringHeader + types are now deprecated. In new code + prefer unsafe.Slice, + unsafe.SliceData, + unsafe.String, + or unsafe.StringData.

-- 2.50.0