]> Cypherpunks repositories - gostls13.git/commitdiff
spec: typo in switch sample code, missing semicolon
authorAndrew Gerrand <adg@golang.org>
Mon, 29 Mar 2010 02:12:08 +0000 (13:12 +1100)
committerAndrew Gerrand <adg@golang.org>
Mon, 29 Mar 2010 02:12:08 +0000 (13:12 +1100)
Fixes #697

R=r
CC=golang-dev
https://golang.org/cl/804042

doc/go_spec.html

index b35af9b037cdcac243016a30af2b2ef1ddaabd72..003bbdc03a5bf669ed94fb5cfba0522ec68a53be 100644 (file)
@@ -3754,7 +3754,7 @@ case 0, 1, 2, 3: s1()
 case 4, 5, 6, 7: s2()
 }
 
-switch x := f() {  // missing switch expression means "true"
+switch x := f(); {  // missing switch expression means "true"
 case x &lt; 0: return -x
 default: return x
 }