From: Robert Griesemer Date: Wed, 16 Sep 2009 18:05:14 +0000 (-0700) Subject: - added syntax for conversions (was missing) X-Git-Tag: weekly.2009-11-06~564 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=5eb36240b7bc54a728ef0f41f206197d48544feb;p=gostls13.git - added syntax for conversions (was missing) - added TODO for syntax for built-ins (require type as first argument) - removed duplicate definition of Index DELTA=13 (11 added, 1 deleted, 1 changed) OCL=34668 CL=34688 --- diff --git a/doc/go_spec.html b/doc/go_spec.html index 6a21c6cabf..7509c0dd0d 100644 --- a/doc/go_spec.html +++ b/doc/go_spec.html @@ -1809,7 +1809,6 @@ ElementList = Element { "," Element } [ "," ] . Element = [ Key ":" ] Value . Key = FieldName | Index . FieldName = identifier . -Index = Expression . Value = Expression . @@ -1996,6 +1995,7 @@ as they are accessible.
 PrimaryExpr =
 	Operand |
+	Conversion |
 	PrimaryExpr Selector |
 	PrimaryExpr Index |
 	PrimaryExpr Slice |
@@ -3906,7 +3906,7 @@ space allocated in the underlying array (for a slice) or map. For a slice
 Conversions look like function calls of the form
 

-
+
 T(value)
 
@@ -3915,6 +3915,12 @@ where T is a type and value is an expression that can be converted to a value of result type T. +

+ +
+Conversion = ( TypeName | "(" Type ")" ) Expression .
+
+

The following conversion rules apply:

@@ -4058,6 +4064,10 @@ c := make(chan int, 10); # channel with a buffer size of 10 m := make(map[string] int, 100); # map with initial space for 100 elements
+

+TODO: Need syntax that permits a type as first argument for built-ins. +

+

Packages