]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Document default parameter of .seek() in the signature. (GH-14691)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Thu, 11 Jul 2019 02:49:37 +0000 (19:49 -0700)
committerGitHub <noreply@github.com>
Thu, 11 Jul 2019 02:49:37 +0000 (19:49 -0700)
(cherry picked from commit 2a3d4d9c53dd4831c3ecf56bc7c4a289c33030d6)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
Doc/library/io.rst

index 966fb9cc766384459604a89f5e404bc468d52b0f..6bf56bc415b2728acf329d00a1986d0d41147582 100644 (file)
@@ -306,7 +306,7 @@ I/O Base Classes
       Note that it's already possible to iterate on file objects using ``for
       line in file: ...`` without calling ``file.readlines()``.
 
-   .. method:: seek(offset[, whence])
+   .. method:: seek(offset, whence=SEEK_SET)
 
       Change the stream position to the given byte *offset*.  *offset* is
       interpreted relative to the position indicated by *whence*.  The default
@@ -810,7 +810,7 @@ Text I/O
 
       If *size* is specified, at most *size* characters will be read.
 
-   .. method:: seek(offset[, whence])
+   .. method:: seek(offset, whence=SEEK_SET)
 
       Change the stream position to the given *offset*.  Behaviour depends on
       the *whence* parameter.  The default value for *whence* is