]> Cypherpunks repositories - gostls13.git/commit
io: Add example to io.Seeker's Seek() method.
authorGreg Poirier <greg.istehbest@gmail.com>
Sat, 15 Jul 2017 18:03:33 +0000 (12:03 -0600)
committerBrad Fitzpatrick <bradfitz@golang.org>
Sat, 15 Jul 2017 19:36:41 +0000 (19:36 +0000)
commit0a633c3bbef4764ab486a0cb0ba154c5db099eac
tree19f98cea158a8187cc98de51db3232c3563fdc2c
parent0593ad1e235d324d928fd045bb97098cb3bd1c66
io: Add example to io.Seeker's Seek() method.

While there's an example for SectionReader.Seek, if someone is
seeking documentation specifically about Seeker.Seek, they may
not immediately find the SectionReader example. Offset and whence
may not be entirely intuitive to new developers either, so include
examples of both positive/negative offsets and SeekStart/SeekEnd.

Change-Id: I5b7442ccf683d9706e9261c11bc0ea31a1ac21d4
Reviewed-on: https://go-review.googlesource.com/48873
Reviewed-by: Kevin Burke <kev@inburke.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/io/example_test.go