aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Griesemer <gri@golang.org>2009-11-09 12:35:56 -0800
committerRobert Griesemer <gri@golang.org>2009-11-09 12:35:56 -0800
commitfb5fce5532b2f18dfa2e9ea964e0365a1edbe69a (patch)
tree0138f09e9d04268a7709a7669d617c04a8d45939
parent40621d5c0d3f9fc222089967ab1aec44e94b5f78 (diff)
downloadgo-fb5fce5532b2f18dfa2e9ea964e0365a1edbe69a.tar.gz
go-fb5fce5532b2f18dfa2e9ea964e0365a1edbe69a.zip
fix for incorrect composite literal grammar
(issue found by ken) R=go-dev, rsc http://go/go-review/1025030
-rw-r--r--doc/go_spec.html3
1 files changed, 2 insertions, 1 deletions
diff --git a/doc/go_spec.html b/doc/go_spec.html
index 5860eec7f0..376046b77d 100644
--- a/doc/go_spec.html
+++ b/doc/go_spec.html
@@ -1890,8 +1890,9 @@ LiteralType = StructType | ArrayType | "[" "..." "]" ElementType |
SliceType | MapType | TypeName | "(" LiteralType ")" .
ElementList = Element { "," Element } [ "," ] .
Element = [ Key ":" ] Value .
-Key = FieldName | Index .
+Key = FieldName | ElementIndex .
FieldName = identifier .
+ElementIndex = Expression .
Value = Expression .
</pre>