<p>
A type declaration binds an identifier, the <i>type name</i>, to a <a href="#Types">type</a>.
Type declarations come in two forms: alias declarations and type definitions.
-<p>
+</p>
<pre class="ebnf">
TypeDecl = "type" ( TypeSpec | "(" { TypeSpec ";" } ")" ) .
</p>
<pre>
-p1 := &[]int{} // p1 points to an initialized, empty slice with value []int{} and length 0
+p1 := &[]int{} // p1 points to an initialized, empty slice with value []int{} and length 0
p2 := new([]int) // p2 points to an uninitialized slice with value nil and length 0
</pre>
<pre>
var a [10]int
-s1 := a[3:7] // underlying array of s1 is array a; &s1[2] == &a[5]
-s2 := s1[1:4] // underlying array of s2 is underlying array of s1 which is array a; &s2[1] == &a[5]
+s1 := a[3:7] // underlying array of s1 is array a; &s1[2] == &a[5]
+s2 := s1[1:4] // underlying array of s2 is underlying array of s1 which is array a; &s2[1] == &a[5]
s2[1] = 42 // s2[1] == s1[2] == a[5] == 42; they all refer to the same underlying array element
</pre>