summaryrefslogtreecommitdiffstats
path: root/Doc/library/base64.rst
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2010-09-15 11:11:28 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2010-09-15 11:11:28 (GMT)
commit11cb961b38550443d287b2b55174e504c2309af2 (patch)
tree51b2972800e593dde1b5f5154b9b044058a350d7 /Doc/library/base64.rst
parent6a11a98b7c8f576d7663182cbd09123eb108a928 (diff)
downloadcpython-11cb961b38550443d287b2b55174e504c2309af2.zip
cpython-11cb961b38550443d287b2b55174e504c2309af2.tar.gz
cpython-11cb961b38550443d287b2b55174e504c2309af2.tar.bz2
Add cross-references to the glossary entry for file objects.
Diffstat (limited to 'Doc/library/base64.rst')
-rw-r--r--Doc/library/base64.rst15
1 files changed, 7 insertions, 8 deletions
diff --git a/Doc/library/base64.rst b/Doc/library/base64.rst
index 39a466e..e282ea0 100644
--- a/Doc/library/base64.rst
+++ b/Doc/library/base64.rst
@@ -122,9 +122,9 @@ The legacy interface:
.. function:: decode(input, output)
Decode the contents of the binary *input* file and write the resulting binary
- data to the *output* file. *input* and *output* must either be file objects
- or objects that mimic the file object interface working with bytes
- objects. *input* will be read until ``input.read()`` returns an empty string.
+ data to the *output* file. *input* and *output* must be :term:`file objects
+ <file object>`. *input* will be read until ``input.read()`` returns an empty
+ bytes object.
.. function:: decodebytes(s)
@@ -138,11 +138,10 @@ The legacy interface:
.. function:: encode(input, output)
Encode the contents of the binary *input* file and write the resulting base64
- encoded data to the *output* file. *input* and *output* must either be file
- objects or objects that mimic the file object interface working with bytes
- objects. *input* will be read until ``input.read()`` returns an empty string.
- :func:`encode` returns the encoded data plus a trailing newline character
- (``b'\n'``).
+ encoded data to the *output* file. *input* and *output* must be :term:`file
+ objects <file object>`. *input* will be read until ``input.read()`` returns
+ an empty bytes object. :func:`encode` returns the encoded data plus a trailing
+ newline character (``b'\n'``).
.. function:: encodebytes(s)