diff options
author | Rob Pike <r@golang.org> | 2012-02-22 16:25:55 +1100 |
---|---|---|
committer | Rob Pike <r@golang.org> | 2012-02-22 16:25:55 +1100 |
commit | 818e3cdb096354dbe1a08581fd432392683529b2 (patch) | |
tree | 1967dc3352fbb28de72ec10c75c20e37be552126 | |
parent | d1e1367cadc92ed6773374ef8379ee222bf554ce (diff) | |
download | go-818e3cdb096354dbe1a08581fd432392683529b2.tar.gz go-818e3cdb096354dbe1a08581fd432392683529b2.zip |
spec: refine the wording about variables in type switches
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/5686064
-rw-r--r-- | doc/go_spec.html | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/doc/go_spec.html b/doc/go_spec.html index 6401fed869..6cc1b2c3d0 100644 --- a/doc/go_spec.html +++ b/doc/go_spec.html @@ -1,6 +1,6 @@ <!--{ "Title": "The Go Programming Language Specification", - "Subtitle": "Version of February 21, 2012" + "Subtitle": "Version of February 22, 2012" }--> <!-- @@ -4023,7 +4023,8 @@ TypeList = Type { "," Type } . <p> The TypeSwitchGuard may include a <a href="#Short_variable_declarations">short variable declaration</a>. -When that form is used, the variable is declared in each clause. +When that form is used, the variable is declared at the beginning of +the <a href="#Blocks">implicit block</a> in each clause. In clauses with a case listing exactly one type, the variable has that type; otherwise, the variable has the type of the expression in the TypeSwitchGuard. |