summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Pike <r@golang.org>2014-03-21 08:37:27 +1100
committerRob Pike <r@golang.org>2014-03-21 08:37:27 +1100
commitabf45ee54d888361bc8b68bff630f677d9035bb3 (patch)
tree93add897fb2d8883e5ec34675258e2ca900c615d
parent06c97ee07682e6ecf4b04f6fc1cd935973855a47 (diff)
downloadgo-abf45ee54d888361bc8b68bff630f677d9035bb3.tar.gz
doc/effective_go.html: fix typo
Prose referred to 'b', code used 'buf'. Fixes issue 7601. LGTM=dominik.honnef R=golang-codereviews, dominik.honnef CC=golang-codereviews https://codereview.appspot.com/78470043
-rw-r--r--doc/effective_go.html7
1 files changed, 4 insertions, 3 deletions
diff --git a/doc/effective_go.html b/doc/effective_go.html
index 74f9f3db9..6006724e5 100644
--- a/doc/effective_go.html
+++ b/doc/effective_go.html
@@ -1386,8 +1386,9 @@ func (file *File) Read(buf []byte) (n int, err error)
</pre>
<p>
The method returns the number of bytes read and an error value, if
-any. To read into the first 32 bytes of a larger buffer
-<code>b</code>, <i>slice</i> (here used as a verb) the buffer.
+any.
+To read into the first 32 bytes of a larger buffer
+<code>buf</code>, <i>slice</i> (here used as a verb) the buffer.
</p>
<pre>
n, err := f.Read(buf[0:32])
@@ -1488,7 +1489,7 @@ If the slices might grow or shrink, they should be allocated independently
to avoid overwriting the next line; if not, it can be more efficient to construct
the object with a single allocation.
For reference, here are sketches of the two methods.
-First, a line a time:
+First, a line at a time:
</p>
<pre>