1
0
mirror of https://github.com/golang/go synced 2024-11-26 07:17:59 -07:00

spec: correct example comment in Conversions from slice to array

Fixes #47280

Change-Id: I78a8d235949b4878c7f075ac4ca37700e7e6c31c
GitHub-Last-Rev: 067f96eeb2
GitHub-Pull-Request: golang/go#47282
Reviewed-on: https://go-review.googlesource.com/c/go/+/335470
Reviewed-by: Robert Griesemer <gri@golang.org>
Trust: Robert Griesemer <gri@golang.org>
Trust: Than McIntosh <thanm@google.com>
This commit is contained in:
Piers 2021-07-19 20:11:29 +00:00 committed by Ian Lance Taylor
parent 1d91551b73
commit c8f4e6152d

View File

@ -4334,7 +4334,7 @@ s4 := (*[4]byte)(s) // panics: len([4]byte) > len(s)
var t []string
t0 := (*[0]string)(t) // t0 == nil
t1 := (*[1]string)(t) // panics: len([1]string) > len(s)
t1 := (*[1]string)(t) // panics: len([1]string) > len(t)
</pre>
<h3 id="Constant_expressions">Constant expressions</h3>