LEFT | RIGHT |
1 <!-- title The Go Programming Language Specification --> | 1 <!-- title The Go Programming Language Specification --> |
2 <!-- subtitle Version of November 9, 2011 --> | 2 <!-- subtitle Version of November 13, 2011 --> |
3 | 3 |
4 <!-- | 4 <!-- |
5 TODO | 5 TODO |
6 [ ] need language about function/method calls and parameter passing rules | 6 [ ] need language about function/method calls and parameter passing rules |
7 [ ] last paragraph of #Assignments (constant promotion) should be elsewhere | 7 [ ] last paragraph of #Assignments (constant promotion) should be elsewhere |
8 and mention assignment to empty interface. | 8 and mention assignment to empty interface. |
9 [ ] need to say something about "scope" of selectors? | 9 [ ] need to say something about "scope" of selectors? |
10 [ ] clarify what a field name is in struct declarations | 10 [ ] clarify what a field name is in struct declarations |
11 (struct{T} vs struct {T T} vs struct {t T}) | 11 (struct{T} vs struct {T T} vs struct {t T}) |
12 [ ] need explicit language about the result type of operations | 12 [ ] need explicit language about the result type of operations |
(...skipping 2946 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2959 </li> | 2959 </li> |
2960 <li> | 2960 <li> |
2961 Boolean values are equal if they are either both | 2961 Boolean values are equal if they are either both |
2962 <code>true</code> or both <code>false</code>. | 2962 <code>true</code> or both <code>false</code>. |
2963 </li> | 2963 </li> |
2964 <li> | 2964 <li> |
2965 Pointer values are equal if they point to the same location | 2965 Pointer values are equal if they point to the same location |
2966 or if both are <code>nil</code>. | 2966 or if both are <code>nil</code>. |
2967 </li> | 2967 </li> |
2968 <li> | 2968 <li> |
2969 » A slice, map, or function value may only be compared to <code>nil</code>
. | 2969 » A slice, map, or function value may be compared only to <code>nil</code>
. |
2970 </li> | 2970 </li> |
2971 <li> | 2971 <li> |
2972 Channel values are equal if they were created by the same call to <code>
make</code> | 2972 Channel values are equal if they were created by the same call to <code>
make</code> |
2973 (§<a href="#Making_slices_maps_and_channels">Making slices, maps, and ch
annels</a>) | 2973 (§<a href="#Making_slices_maps_and_channels">Making slices, maps, and ch
annels</a>) |
2974 or if both are <code>nil</code>. | 2974 or if both are <code>nil</code>. |
2975 </li> | 2975 </li> |
2976 <li> | 2976 <li> |
2977 Interface values are equal if they have <a href="#Type_identity">identic
al</a> dynamic types and | 2977 Interface values are equal if they have <a href="#Type_identity">identic
al</a> dynamic types and |
2978 equal dynamic values or if both are <code>nil</code>. | 2978 equal dynamic values or if both are <code>nil</code>. |
2979 </li> | 2979 </li> |
(...skipping 2343 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5323 <code>unsafe.Alignof(x[0])</code>, but at least 1. | 5323 <code>unsafe.Alignof(x[0])</code>, but at least 1. |
5324 </li> | 5324 </li> |
5325 </ol> | 5325 </ol> |
5326 | 5326 |
5327 <span class="alert"> | 5327 <span class="alert"> |
5328 <h2 id="Implementation_differences">Implementation differences - TODO</h2> | 5328 <h2 id="Implementation_differences">Implementation differences - TODO</h2> |
5329 <ul> | 5329 <ul> |
5330 <li><code>len(a)</code> is only a constant if <code>a</code> is a (quali
fied) identifier denoting an array or pointer to an array.</li> | 5330 <li><code>len(a)</code> is only a constant if <code>a</code> is a (quali
fied) identifier denoting an array or pointer to an array.</li> |
5331 </ul> | 5331 </ul> |
5332 </span> | 5332 </span> |
LEFT | RIGHT |