diff options
author | Georg Brandl <georg@python.org> | 2009-05-17 12:29:12 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2009-05-17 12:29:12 (GMT) |
commit | 71515ca191f32651c923c70e891632b4ac820b4f (patch) | |
tree | d6694e4aabe615b76ca113374bf35cd817fca330 | |
parent | ef0a865f9c906a1298c43a453b2195d86befd6a4 (diff) | |
download | cpython-71515ca191f32651c923c70e891632b4ac820b4f.zip cpython-71515ca191f32651c923c70e891632b4ac820b4f.tar.gz cpython-71515ca191f32651c923c70e891632b4ac820b4f.tar.bz2 |
Remove surplus empty lines and convert more files to new optional arg style.
39 files changed, 38 insertions, 74 deletions
diff --git a/Doc/library/abc.rst b/Doc/library/abc.rst index 29d37f3..aa1cc78 100644 --- a/Doc/library/abc.rst +++ b/Doc/library/abc.rst @@ -1,4 +1,3 @@ - :mod:`abc` --- Abstract Base Classes ==================================== diff --git a/Doc/library/allos.rst b/Doc/library/allos.rst index 6c5837d..f25c3b8 100644 --- a/Doc/library/allos.rst +++ b/Doc/library/allos.rst @@ -1,4 +1,3 @@ - .. _allos: ********************************* diff --git a/Doc/library/archiving.rst b/Doc/library/archiving.rst index 7d0df5f..f2d08ad 100644 --- a/Doc/library/archiving.rst +++ b/Doc/library/archiving.rst @@ -1,4 +1,3 @@ - .. _archiving: ****************************** diff --git a/Doc/library/array.rst b/Doc/library/array.rst index 4900509..200277f 100644 --- a/Doc/library/array.rst +++ b/Doc/library/array.rst @@ -1,4 +1,3 @@ - :mod:`array` --- Efficient arrays of numeric values =================================================== diff --git a/Doc/library/asynchat.rst b/Doc/library/asynchat.rst index 4adaecf..e511a05 100644 --- a/Doc/library/asynchat.rst +++ b/Doc/library/asynchat.rst @@ -1,4 +1,3 @@ - :mod:`asynchat` --- Asynchronous socket command/response handler ================================================================ diff --git a/Doc/library/asyncore.rst b/Doc/library/asyncore.rst index 267c58b..60d4d03 100644 --- a/Doc/library/asyncore.rst +++ b/Doc/library/asyncore.rst @@ -1,4 +1,3 @@ - :mod:`asyncore` --- Asynchronous socket handler =============================================== diff --git a/Doc/library/atexit.rst b/Doc/library/atexit.rst index 74712ee..db90218 100644 --- a/Doc/library/atexit.rst +++ b/Doc/library/atexit.rst @@ -1,4 +1,3 @@ - :mod:`atexit` --- Exit handlers =============================== diff --git a/Doc/library/audioop.rst b/Doc/library/audioop.rst index fe6e86f..4af8536 100644 --- a/Doc/library/audioop.rst +++ b/Doc/library/audioop.rst @@ -1,4 +1,3 @@ - :mod:`audioop` --- Manipulate raw audio data ============================================ diff --git a/Doc/library/base64.rst b/Doc/library/base64.rst index 1e78953..62bf1d4 100644 --- a/Doc/library/base64.rst +++ b/Doc/library/base64.rst @@ -1,4 +1,3 @@ - :mod:`base64` --- RFC 3548: Base16, Base32, Base64 Data Encodings ================================================================= diff --git a/Doc/library/binascii.rst b/Doc/library/binascii.rst index 8488743..c42f81f 100644 --- a/Doc/library/binascii.rst +++ b/Doc/library/binascii.rst @@ -1,4 +1,3 @@ - :mod:`binascii` --- Convert between binary and ASCII ==================================================== diff --git a/Doc/library/code.rst b/Doc/library/code.rst index 4219e9e..56214b9 100644 --- a/Doc/library/code.rst +++ b/Doc/library/code.rst @@ -1,4 +1,3 @@ - :mod:`code` --- Interpreter base classes ======================================== @@ -6,7 +5,6 @@ :synopsis: Facilities to implement read-eval-print loops. - The ``code`` module provides facilities to implement read-eval-print loops in Python. Two classes and convenience functions are included which can be used to build applications which provide an interactive interpreter prompt. diff --git a/Doc/library/codeop.rst b/Doc/library/codeop.rst index fb2f326..9ae4176 100644 --- a/Doc/library/codeop.rst +++ b/Doc/library/codeop.rst @@ -1,4 +1,3 @@ - :mod:`codeop` --- Compile Python code ===================================== diff --git a/Doc/library/collections.rst b/Doc/library/collections.rst index fca84bd..9dcf302 100644 --- a/Doc/library/collections.rst +++ b/Doc/library/collections.rst @@ -1,4 +1,3 @@ - :mod:`collections` --- Container datatypes ========================================== diff --git a/Doc/library/compileall.rst b/Doc/library/compileall.rst index 52f881b..83e418d 100644 --- a/Doc/library/compileall.rst +++ b/Doc/library/compileall.rst @@ -1,4 +1,3 @@ - :mod:`compileall` --- Byte-compile Python libraries =================================================== diff --git a/Doc/library/contextlib.rst b/Doc/library/contextlib.rst index e2ca6a1..d6ce9a7 100644 --- a/Doc/library/contextlib.rst +++ b/Doc/library/contextlib.rst @@ -1,4 +1,3 @@ - :mod:`contextlib` --- Utilities for :keyword:`with`\ -statement contexts. ========================================================================= diff --git a/Doc/library/copy.rst b/Doc/library/copy.rst index 554801f..e6ad857 100644 --- a/Doc/library/copy.rst +++ b/Doc/library/copy.rst @@ -1,4 +1,3 @@ - :mod:`copy` --- Shallow and deep copy operations ================================================ diff --git a/Doc/library/copyreg.rst b/Doc/library/copyreg.rst index 60df3d0..f6dbaaf 100644 --- a/Doc/library/copyreg.rst +++ b/Doc/library/copyreg.rst @@ -1,6 +1,5 @@ - :mod:`copyreg` --- Register :mod:`pickle` support functions -============================================================ +=========================================================== .. module:: copyreg :synopsis: Register pickle support functions. diff --git a/Doc/library/crypt.rst b/Doc/library/crypt.rst index b6c3d21..0be571e 100644 --- a/Doc/library/crypt.rst +++ b/Doc/library/crypt.rst @@ -1,4 +1,3 @@ - :mod:`crypt` --- Function to check Unix passwords ================================================= diff --git a/Doc/library/crypto.rst b/Doc/library/crypto.rst index dce5a01..8650094 100644 --- a/Doc/library/crypto.rst +++ b/Doc/library/crypto.rst @@ -1,4 +1,3 @@ - .. _crypto: ********************** diff --git a/Doc/library/csv.rst b/Doc/library/csv.rst index 87ed3b6..6bcee11 100644 --- a/Doc/library/csv.rst +++ b/Doc/library/csv.rst @@ -1,4 +1,3 @@ - :mod:`csv` --- CSV File Reading and Writing =========================================== diff --git a/Doc/library/ctypes.rst b/Doc/library/ctypes.rst index e389a63..ac2f2fd 100644 --- a/Doc/library/ctypes.rst +++ b/Doc/library/ctypes.rst @@ -1,6 +1,5 @@ - -:mod:`ctypes` --- A foreign function library for Python. -======================================================== +:mod:`ctypes` --- A foreign function library for Python +======================================================= .. module:: ctypes :synopsis: A foreign function library for Python. diff --git a/Doc/library/curses.ascii.rst b/Doc/library/curses.ascii.rst index cf51f78..6bc1fb9 100644 --- a/Doc/library/curses.ascii.rst +++ b/Doc/library/curses.ascii.rst @@ -1,4 +1,3 @@ - :mod:`curses.ascii` --- Utilities for ASCII characters ====================================================== diff --git a/Doc/library/curses.panel.rst b/Doc/library/curses.panel.rst index 59e5b86..a3c8bda 100644 --- a/Doc/library/curses.panel.rst +++ b/Doc/library/curses.panel.rst @@ -1,6 +1,5 @@ - -:mod:`curses.panel` --- A panel stack extension for curses. -=========================================================== +:mod:`curses.panel` --- A panel stack extension for curses +========================================================== .. module:: curses.panel :synopsis: A panel stack extension that adds depth to curses windows. diff --git a/Doc/library/curses.rst b/Doc/library/curses.rst index b16d667..03f8f8c 100644 --- a/Doc/library/curses.rst +++ b/Doc/library/curses.rst @@ -1,9 +1,9 @@ - :mod:`curses` --- Terminal handling for character-cell displays =============================================================== .. module:: curses - :synopsis: An interface to the curses library, providing portable terminal handling. + :synopsis: An interface to the curses library, providing portable + terminal handling. .. sectionauthor:: Moshe Zadka <moshez@zadka.site.co.il> .. sectionauthor:: Eric Raymond <esr@thyrsus.com> diff --git a/Doc/library/custominterp.rst b/Doc/library/custominterp.rst index 2a9f0a4..5eeced2 100644 --- a/Doc/library/custominterp.rst +++ b/Doc/library/custominterp.rst @@ -1,4 +1,3 @@ - .. _custominterp: ************************** diff --git a/Doc/library/datatypes.rst b/Doc/library/datatypes.rst index 99d062b..6b4a71a 100644 --- a/Doc/library/datatypes.rst +++ b/Doc/library/datatypes.rst @@ -1,4 +1,3 @@ - .. _datatypes: ********** diff --git a/Doc/library/decimal.rst b/Doc/library/decimal.rst index a27fbf4..d548c0d 100644 --- a/Doc/library/decimal.rst +++ b/Doc/library/decimal.rst @@ -1,4 +1,3 @@ - :mod:`decimal` --- Decimal fixed point and floating point arithmetic ==================================================================== diff --git a/Doc/library/development.rst b/Doc/library/development.rst index 8cd3d0c..c822e08 100644 --- a/Doc/library/development.rst +++ b/Doc/library/development.rst @@ -1,4 +1,3 @@ - .. _development: ***************** diff --git a/Doc/library/dis.rst b/Doc/library/dis.rst index c5a7ea8..8d4d956 100644 --- a/Doc/library/dis.rst +++ b/Doc/library/dis.rst @@ -1,4 +1,3 @@ - :mod:`dis` --- Disassembler for Python bytecode =============================================== @@ -6,11 +5,11 @@ :synopsis: Disassembler for Python bytecode. -The :mod:`dis` module supports the analysis of Python :term:`bytecode` by disassembling -it. Since there is no Python assembler, this module defines the Python assembly -language. The Python bytecode which this module takes as an input is defined -in the file :file:`Include/opcode.h` and used by the compiler and the -interpreter. +The :mod:`dis` module supports the analysis of Python :term:`bytecode` by +disassembling it. Since there is no Python assembler, this module defines the +Python assembly language. The Python bytecode which this module takes as an +input is defined in the file :file:`Include/opcode.h` and used by the compiler +and the interpreter. Example: Given the function :func:`myfunc`:: diff --git a/Doc/library/distutils.rst b/Doc/library/distutils.rst index 534faab..238b79d 100644 --- a/Doc/library/distutils.rst +++ b/Doc/library/distutils.rst @@ -1,10 +1,9 @@ - :mod:`distutils` --- Building and installing Python modules =========================================================== .. module:: distutils - :synopsis: Support for building and installing Python modules into an existing Python - installation. + :synopsis: Support for building and installing Python modules into an + existing Python installation. .. sectionauthor:: Fred L. Drake, Jr. <fdrake@acm.org> @@ -19,12 +18,12 @@ This package is discussed in two separate chapters: .. seealso:: :ref:`distutils-index` - The manual for developers and packagers of Python modules. This describes how - to prepare :mod:`distutils`\ -based packages so that they may be easily - installed into an existing Python installation. + The manual for developers and packagers of Python modules. This describes + how to prepare :mod:`distutils`\ -based packages so that they may be + easily installed into an existing Python installation. :ref:`install-index` - An "administrators" manual which includes information on installing modules into - an existing Python installation. You do not need to be a Python programmer to - read this manual. + An "administrators" manual which includes information on installing + modules into an existing Python installation. You do not need to be a + Python programmer to read this manual. diff --git a/Doc/library/errno.rst b/Doc/library/errno.rst index daf9ff0..d2163b6 100644 --- a/Doc/library/errno.rst +++ b/Doc/library/errno.rst @@ -1,4 +1,3 @@ - :mod:`errno` --- Standard errno system symbols ============================================== diff --git a/Doc/library/fcntl.rst b/Doc/library/fcntl.rst index 0e69407..a397afc 100644 --- a/Doc/library/fcntl.rst +++ b/Doc/library/fcntl.rst @@ -1,4 +1,3 @@ - :mod:`fcntl` --- The :func:`fcntl` and :func:`ioctl` system calls ================================================================= @@ -65,13 +64,13 @@ The module defines the following functions: so long as the buffer you pass is as least as long as what the operating system wants to put there, things should work. - If *mutate_flag* is true (the default), then the buffer is (in effect) passed to the - underlying :func:`ioctl` system call, the latter's return code is passed back to - the calling Python, and the buffer's new contents reflect the action of the - :func:`ioctl`. This is a slight simplification, because if the supplied buffer - is less than 1024 bytes long it is first copied into a static buffer 1024 bytes - long which is then passed to :func:`ioctl` and copied back into the supplied - buffer. + If *mutate_flag* is true (the default), then the buffer is (in effect) passed + to the underlying :func:`ioctl` system call, the latter's return code is + passed back to the calling Python, and the buffer's new contents reflect the + action of the :func:`ioctl`. This is a slight simplification, because if the + supplied buffer is less than 1024 bytes long it is first copied into a static + buffer 1024 bytes long which is then passed to :func:`ioctl` and copied back + into the supplied buffer. An example:: diff --git a/Doc/library/filecmp.rst b/Doc/library/filecmp.rst index 11d74ba..f57dcce 100644 --- a/Doc/library/filecmp.rst +++ b/Doc/library/filecmp.rst @@ -1,4 +1,3 @@ - :mod:`filecmp` --- File and Directory Comparisons ================================================= @@ -14,7 +13,7 @@ see also the :mod:`difflib` module. The :mod:`filecmp` module defines the following functions: -.. function:: cmp(f1, f2[, shallow]) +.. function:: cmp(f1, f2, shallow=True) Compare the files named *f1* and *f2*, returning ``True`` if they seem equal, ``False`` otherwise. @@ -29,7 +28,7 @@ The :mod:`filecmp` module defines the following functions: portability and efficiency. -.. function:: cmpfiles(dir1, dir2, common[, shallow]) +.. function:: cmpfiles(dir1, dir2, common, shallow=True) Compare the files in the two directories *dir1* and *dir2* whose names are given by *common*. @@ -66,7 +65,7 @@ The :class:`dircmp` class :class:`dircmp` instances are built using this constructor: -.. class:: dircmp(a, b[, ignore[, hide]]) +.. class:: dircmp(a, b, ignore=None, hide=None) Construct a new directory comparison object, to compare the directories *a* and *b*. *ignore* is a list of names to ignore, and defaults to ``['RCS', 'CVS', @@ -159,5 +158,6 @@ The :class:`dircmp` class .. attribute:: subdirs - A dictionary mapping names in :attr:`common_dirs` to :class:`dircmp` objects. + A dictionary mapping names in :attr:`common_dirs` to :class:`dircmp` + objects. diff --git a/Doc/library/fileformats.rst b/Doc/library/fileformats.rst index dc2e237..980d4f5 100644 --- a/Doc/library/fileformats.rst +++ b/Doc/library/fileformats.rst @@ -1,4 +1,3 @@ - .. _fileformats: ************ diff --git a/Doc/library/fileinput.rst b/Doc/library/fileinput.rst index 76d5d6f..d98a198 100644 --- a/Doc/library/fileinput.rst +++ b/Doc/library/fileinput.rst @@ -47,7 +47,7 @@ provided by this module. The following function is the primary interface of this module: -.. function:: input([files[, inplace[, backup[, mode[, openhook]]]]]) +.. function:: input(files=None, inplace=False, backup='', bufsize=0, mode='r', openhook=None) Create an instance of the :class:`FileInput` class. The instance will be used as global state for the functions of this module, and is also returned to use @@ -115,7 +115,7 @@ The class which implements the sequence behavior provided by the module is available for subclassing as well: -.. class:: FileInput([files[, inplace[, backup[, mode[, openhook]]]]]) +.. class:: FileInput(files=None, inplace=False, backup='', bufsize=0, mode='r', openhook=None) Class :class:`FileInput` is the implementation; its methods :meth:`filename`, :meth:`fileno`, :meth:`lineno`, :meth:`filelineno`, :meth:`isfirstline`, diff --git a/Doc/library/filesys.rst b/Doc/library/filesys.rst index 41f7716..b341f5f 100644 --- a/Doc/library/filesys.rst +++ b/Doc/library/filesys.rst @@ -1,4 +1,3 @@ - .. _filesys: ************************* diff --git a/Doc/library/fnmatch.rst b/Doc/library/fnmatch.rst index 1bb2cf2..7561880 100644 --- a/Doc/library/fnmatch.rst +++ b/Doc/library/fnmatch.rst @@ -1,4 +1,3 @@ - :mod:`fnmatch` --- Unix filename pattern matching ================================================= diff --git a/Doc/library/formatter.rst b/Doc/library/formatter.rst index c983ccc..0a459a6 100644 --- a/Doc/library/formatter.rst +++ b/Doc/library/formatter.rst @@ -165,7 +165,7 @@ The following attributes are defined for formatter instance objects: :const:`AS_IS` values, is passed to the writer's :meth:`new_styles` method. -.. method:: formatter.pop_style([n=1]) +.. method:: formatter.pop_style(n=1) Pop the last *n* style specifications passed to :meth:`push_style`. A tuple representing the revised stack, including :const:`AS_IS` values, is passed to @@ -177,7 +177,7 @@ The following attributes are defined for formatter instance objects: Set the spacing style for the writer. -.. method:: formatter.assert_line_data([flag=1]) +.. method:: formatter.assert_line_data(flag=1) Inform the formatter that data has been added to the current paragraph out-of-band. This should be used when the writer has been manipulated @@ -194,7 +194,7 @@ Two implementations of formatter objects are provided by this module. Most applications may use one of these classes without modification or subclassing. -.. class:: NullFormatter([writer]) +.. class:: NullFormatter(writer=None) A formatter which does nothing. If *writer* is omitted, a :class:`NullWriter` instance is created. No methods of the writer are called by @@ -337,7 +337,7 @@ this module. Most applications will need to derive new writer classes from the output. -.. class:: DumbWriter([file[, maxcol=72]]) +.. class:: DumbWriter(file=None, maxcol=72) Simple writer class which writes output on the file object passed in as *file* or, if *file* is omitted, on standard output. The output is simply word-wrapped diff --git a/Doc/library/fpectl.rst b/Doc/library/fpectl.rst index ef030f0..fb15f69 100644 --- a/Doc/library/fpectl.rst +++ b/Doc/library/fpectl.rst @@ -1,4 +1,3 @@ - :mod:`fpectl` --- Floating point exception control ================================================== |