summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2008-06-10 15:50:56 (GMT)
committerGeorg Brandl <georg@python.org>2008-06-10 15:50:56 (GMT)
commit0312494665ba9a6492956183c181e1b87e10820d (patch)
treef5965d4f17e7d075661728a5f25e608e32bd5f62 /Doc
parentb1ef6735ba175d243b3bb8d7f46c53ffbecfb7bd (diff)
downloadcpython-0312494665ba9a6492956183c181e1b87e10820d.zip
cpython-0312494665ba9a6492956183c181e1b87e10820d.tar.gz
cpython-0312494665ba9a6492956183c181e1b87e10820d.tar.bz2
Remove last traces of cStringIO.
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/csv.rst4
-rw-r--r--Doc/library/email.message.rst2
-rw-r--r--Doc/library/pickle.rst2
3 files changed, 4 insertions, 4 deletions
diff --git a/Doc/library/csv.rst b/Doc/library/csv.rst
index 6beadc5..9043dbc 100644
--- a/Doc/library/csv.rst
+++ b/Doc/library/csv.rst
@@ -484,7 +484,7 @@ For all other encodings the following :class:`UnicodeReader` and
parameter in their constructor and make sure that the data passes the real
reader or writer encoded as UTF-8::
- import csv, codecs, cStringIO
+ import csv, codecs, io
class UTF8Recoder:
"""
@@ -524,7 +524,7 @@ reader or writer encoded as UTF-8::
def __init__(self, f, dialect=csv.excel, encoding="utf-8", **kwds):
# Redirect output to a queue
- self.queue = cStringIO.StringIO()
+ self.queue = io.StringIO()
self.writer = csv.writer(self.queue, dialect=dialect, **kwds)
self.stream = f
self.encoder = codecs.getincrementalencoder(encoding)()
diff --git a/Doc/library/email.message.rst b/Doc/library/email.message.rst
index 5344b45..f51230c 100644
--- a/Doc/library/email.message.rst
+++ b/Doc/library/email.message.rst
@@ -48,7 +48,7 @@ Here are the methods of the :class:`Message` class:
:class:`Generator` instance and use its :meth:`flatten` method directly.
For example::
- from cStringIO import StringIO
+ from io import StringIO
from email.generator import Generator
fp = StringIO()
g = Generator(fp, mangle_from_=False, maxheaderlen=60)
diff --git a/Doc/library/pickle.rst b/Doc/library/pickle.rst
index 2194523..76248ac 100644
--- a/Doc/library/pickle.rst
+++ b/Doc/library/pickle.rst
@@ -555,7 +555,7 @@ the referenced object.
Here's a silly example that *might* shed more light::
import pickle
- from cStringIO import StringIO
+ from io import StringIO
src = StringIO()
p = pickle.Pickler(src)