Commit 31f2503c authored by Robert Griesemer's avatar Robert Griesemer

go spec: Disallow &a notation to obtain a slice

from an array; one needs to write a[0:] instead.

R=rsc, r, iant, ken2
CC=golang-dev
https://golang.org/cl/1365041
parent 1fda1323
<!-- title The Go Programming Language Specification -->
<!-- subtitle Version of May 24, 2010 -->
<!-- subtitle Version of May 26, 2010 -->
<!--
Todo
......@@ -1344,12 +1344,6 @@ with a type <code>T</code> if one or more of the following conditions applies:
<code>V</code> <a href="#Interface_types">implements</a> <code>T</code>.
</li>
<li>
<code>V</code> is a pointer to an array and <code>T</code> is a slice type
with compatible element type and at least one of <code>V</code> or <code>T</code> is unnamed.
After assignment, the slice variable refers to the original array; the elements are not
copied.
</li>
<li>
<code>V</code> is a bidirectional channel and <code>T</code> is a channel type
with compatible element type and at least one of <code>V</code> or <code>T</code> is unnamed.
</li>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment