diff -r f1094697d7dc Doc/library/fileinput.rst --- a/Doc/library/fileinput.rst Fri Sep 28 17:17:11 2012 +0200 +++ b/Doc/library/fileinput.rst Sat Sep 29 01:01:33 2012 +0300 @@ -143,7 +143,8 @@ sequential order; random access and :meth:`readline` cannot be mixed. With *mode* you can specify which file mode will be passed to :func:`open`. It - must be one of ``'r'``, ``'rU'``, ``'U'`` and ``'rb'``. + must be one of ``'r'``, ``'rU'``, ``'U'`` and ``'rb'``. ``'rU'`` and ``'U'`` + modes are deprecated, unneeded in new code and will not be used in new code. The *openhook*, when given, must be a function that takes two arguments, *filename* and *mode*, and returns an accordingly opened file-like object. You diff -r f1094697d7dc Doc/library/functions.rst --- a/Doc/library/functions.rst Fri Sep 28 17:17:11 2012 +0200 +++ b/Doc/library/functions.rst Sat Sep 29 01:01:33 2012 +0300 @@ -838,7 +838,7 @@ ``'b'`` binary mode ``'t'`` text mode (default) ``'+'`` open a disk file for updating (reading and writing) - ``'U'`` universal newlines mode (for backwards compatibility; should + ``'U'`` universal newlines mode (deprecated; unneeded in new code; should not be used in new code) ========= =============================================================== diff -r f1094697d7dc Doc/library/zipfile.rst --- a/Doc/library/zipfile.rst Fri Sep 28 17:17:11 2012 +0200 +++ b/Doc/library/zipfile.rst Sat Sep 29 01:01:33 2012 +0300 @@ -206,9 +206,10 @@ is the name of the file in the archive, or a :class:`ZipInfo` object. The *mode* parameter, if included, must be one of the following: ``'r'`` (the default), ``'U'``, or ``'rU'``. Choosing ``'U'`` or ``'rU'`` will enable - :term:`universal newlines` support in the read-only object. *pwd* is the - password used for encrypted files. Calling :meth:`open` on a closed - ZipFile will raise a :exc:`RuntimeError`. + :term:`universal newlines` support in the read-only object (deprecated; + should not be used in new code; use :class:`io.TextWrapper` for reading + compressed text files). *pwd* is the password used for encrypted files. + Calling :meth:`open` on a closed ZipFile will raise a :exc:`RuntimeError`. .. note:: diff -r f1094697d7dc Lib/_pyio.py --- a/Lib/_pyio.py Fri Sep 28 17:17:11 2012 +0200 +++ b/Lib/_pyio.py Sat Sep 29 01:01:33 2012 +0300 @@ -62,8 +62,8 @@ 'b' binary mode 't' text mode (default) '+' open a disk file for updating (reading and writing) - 'U' universal newline mode (for backwards compatibility; unneeded - for new code) + 'U' universal newline mode (deprecated; unneeded for new code; should + not be used in new code) ========= =============================================================== The default mode is 'rt' (open for reading text). For binary random diff -r f1094697d7dc Modules/_io/_iomodule.c --- a/Modules/_io/_iomodule.c Fri Sep 28 17:17:11 2012 +0200 +++ b/Modules/_io/_iomodule.c Sat Sep 29 01:01:33 2012 +0300 @@ -126,8 +126,8 @@ "'b' binary mode\n" "'t' text mode (default)\n" "'+' open a disk file for updating (reading and writing)\n" -"'U' universal newline mode (for backwards compatibility; unneeded\n" -" for new code)\n" +"'U' universal newline mode (deprecated; unneeded for new code; should\n" +" not be used in new code)\n" "========= ===============================================================\n" "\n" "The default mode is 'rt' (open for reading text). For binary random\n"