From 614b02d22a66cfcd9f5c9631246b4b529484e642 Mon Sep 17 00:00:00 2001 From: Robert Griesemer Date: Wed, 2 Jan 2013 18:11:49 -0800 Subject: [PATCH] spec: clarify language about unary operator & A composite literal may be parenthesized when used as operand for the unary operator &. R=rsc, iant, r, ken CC=golang-dev https://golang.org/cl/6996053 --- doc/go_spec.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/doc/go_spec.html b/doc/go_spec.html index 0087d8b5ec..ad3fa519b2 100644 --- a/doc/go_spec.html +++ b/doc/go_spec.html @@ -1,6 +1,6 @@ @@ -3246,6 +3246,7 @@ that is, either a variable, pointer indirection, or slice indexing operation; or a field selector of an addressable struct operand; or an array indexing operation of an addressable array. As an exception to the addressability requirement, x may also be a +(possibly parenthesized) composite literal.

@@ -3259,6 +3260,7 @@ will cause a run-time panic.

 &x
 &a[f(2)]
+&Point{2, 3}
 *p
 *pf(x)
 
-- 2.48.1