Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go
Commits
7c9ee5f3
Commit
7c9ee5f3
authored
Jan 25, 2012
by
Robert Hencke
Committed by
Rob Pike
Jan 25, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
doc/go1: minor html fixes
R=golang-dev, r CC=golang-dev
https://golang.org/cl/5572064
parent
f8a28ecc
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
8 deletions
+8
-8
doc/go1.html
doc/go1.html
+4
-4
doc/go1.tmpl
doc/go1.tmpl
+4
-4
No files found.
doc/go1.html
View file @
7c9ee5f3
...
...
@@ -74,8 +74,8 @@ to call <code>close</code> on a receive-only channel:
<pre>
var c chan int
var csend chan
<
-
int =
c
var
crecv
<
-chan
int =
c
var csend chan
<
- int = c
var crecv
<
-chan int = c
close(c) // legal
close(csend) // legal
close(crecv) // illegal
...
...
@@ -328,8 +328,8 @@ This function implicitly returns a shadowed return value and will be rejected by
<pre>
func Bug() (i, j, k int) {
for i = 0; i
<
5
;
i
++
{
for
j
:=
0;
j
<
5
;
j
++
{
//
Redeclares
j
.
for i = 0; i
<
5; i++ {
for j := 0; j
<
5; j++ { // Redeclares j.
k += i*j
if k > 100 {
return // Rejected: j is shadowed here.
...
...
doc/go1.tmpl
View file @
7c9ee5f3
...
...
@@ -67,8 +67,8 @@ to call <code>close</code> on a receive-only channel:
<
pre
>
var
c
chan
int
var
csend
chan
<
-
int
=
c
var
crecv
<
-
chan
int
=
c
var
csend
chan
&
lt
;
-
int
=
c
var
crecv
&
lt
;
-
chan
int
=
c
close
(
c
)
//
legal
close
(
csend
)
//
legal
close
(
crecv
)
//
illegal
...
...
@@ -263,8 +263,8 @@ This function implicitly returns a shadowed return value and will be rejected by
<pre>
func Bug() (i, j, k int) {
for i = 0; i
<
5; i++ {
for j := 0; j
<
5; j++ { // Redeclares j.
for i = 0; i
<
5; i++ {
for j := 0; j
<
5; j++ { // Redeclares j.
k += i*j
if k > 100 {
return // Rejected: j is shadowed here.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment