diff options
author | Kyle Consalus <consalus@gmail.com> | 2010-12-01 11:59:13 -0800 |
---|---|---|
committer | Kyle Consalus <consalus@gmail.com> | 2010-12-01 11:59:13 -0800 |
commit | b9d484c56197af603a6b1d373765bfaf10fb283d (patch) | |
tree | 662d594dcc577ae6827ae3a7e3551f36b54e28cd /doc | |
parent | c4dc344e0b1af1a5e4e6ce42698c016cc672d7c8 (diff) | |
download | go-b9d484c56197af603a6b1d373765bfaf10fb283d.tar.gz |
Removed bytes.Add and bytes.AddByte; we now have 'append'.
Changed all uses of bytes.Add (aside from those testing bytes.Add) to append(a, b...).
Also ran "gofmt -s" and made use of copy([]byte, string) in the fasta benchmark.
R=golang-dev, r, r2
CC=golang-dev
http://codereview.appspot.com/3302042
Committer: Rob Pike <r@golang.org>
Diffstat (limited to 'doc')
-rw-r--r-- | doc/effective_go.html | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/doc/effective_go.html b/doc/effective_go.html index 8bb04e917..ab21edfbb 100644 --- a/doc/effective_go.html +++ b/doc/effective_go.html @@ -794,7 +794,7 @@ func Contents(filename string) (string, os.Error) { buf := make([]byte, 100) for { n, err := f.Read(buf[0:]) - result = bytes.Add(result, buf[0:n]) + result = append(result, buf[0:n]...) // append is discussed later. if err != nil { if err == os.EOF { break |