mirror of
https://github.com/golang/go
synced 2024-11-05 18:36:08 +00: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:
parent
1d91551b73
commit
c8f4e6152d
1 changed files with 1 additions and 1 deletions
|
@ -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>
|
||||
|
|
Loading…
Reference in a new issue