From: Robert Griesemer Date: Tue, 22 Jun 2021 05:20:11 +0000 (-0700) Subject: spec: unsafe.Add/Slice are not permitted in statement context X-Git-Tag: go1.17rc1~58 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=5bd09e5efc;p=gostls13.git spec: unsafe.Add/Slice are not permitted in statement context Add unsafe.Add and unsafe.Slice to the list of built-in functions which are not permitted in statement context. The compiler and type checker already enforce this restriction, this just fixes a documentation oversight. For #19367. For #40481. Change-Id: Iabc63a8db048eaf40a5f5b5573fdf00b79d54119 Reviewed-on: https://go-review.googlesource.com/c/go/+/329925 Trust: Robert Griesemer Run-TryBot: Robert Griesemer Reviewed-by: Matthew Dempsky Reviewed-by: Rob Pike TryBot-Result: Go Bot --- diff --git a/doc/go_spec.html b/doc/go_spec.html index 561d44271a..b59b37fd55 100644 --- a/doc/go_spec.html +++ b/doc/go_spec.html @@ -1,6 +1,6 @@ @@ -4670,7 +4670,7 @@ The following built-in functions are not permitted in statement context:
 append cap complex imag len make new real
-unsafe.Alignof unsafe.Offsetof unsafe.Sizeof
+unsafe.Add unsafe.Alignof unsafe.Offsetof unsafe.Sizeof unsafe.Slice