parsing and printing to new syntax.
Use -oldparser to parse the old syntax,
use -oldprinter to print the old syntax.
2) Change default gofmt formatting settings
to use tabs for indentation only and to use
spaces for alignment. This will make the code
alignment insensitive to an editor's tabwidth.
Use -spaces=false to use tabs for alignment.
3) Manually changed src/exp/parser/parser_test.go
so that it doesn't try to parse the parser's
source files using the old syntax (they have
new syntax now).
4) gofmt -w src misc test/bench
1st set of files.
R=rsc
CC=agl, golang-dev, iant, ken2, r
https://golang.org/cl/180047
1. If all data is exhausted using Read then a following Next will
fail as if it saw EOF. (Test case added.)
2. Seeking isn't always possible (i.e. sockets and pipes). Fallback
to read. (Test case added.)
3. Fix to readHeader (cleaner fix pointed out by rsc).
(TestReader modified.)
4. When Read has consumed all the data, don't try to read 0 bytes from reader.
In cases where tr.nb is zero we attempt to read zero bytes and thus
never see an EOF (this is most easily seen when the 'tar source' is
something like bytes.Buffer{} as opposed to os.File).
5. If write is used to the point of ErrWriteTooLong, allow additional file entries.
6. Make close work as expected. That is any further Write or
WriteHeader attempts will result in ErrWriteAfterClose.
Fixes#419.
R=rsc, dsymonds1
https://golang.org/cl/162062
There's no functional change here. io gives the Read and Write methods byte slice arguments, but tar called them uint8. It's the same thing, but I think this is clearer and it matches what other packages do.
R=rsc
CC=golang-dev
https://golang.org/cl/157099
- enabled for function declarations (not just function literals)
- applied gofmt -w $GOROOT/src
(look for instance at src/pkg/debug/elf/elf.go)
R=r, rsc
CC=go-dev
http://go/go-review/1026006
- rename untar{,_test}.go to reader{,_test}.go.
- fix up some comments.
- improve test output if it fails.
R=rsc
APPROVED=rsc
DELTA=821 (400 added, 392 deleted, 29 changed)
OCL=31376
CL=31378