[Python-checkins] r71027 - in python/branches/py3k/Doc/library: abc.rst aifc.rst asynchat.rst atexit.rst base64.rst bdb.rst binascii.rst

georg.brandl python-checkins at python.org
Thu Apr 2 04:56:11 CEST 2009


Author: georg.brandl
Date: Thu Apr  2 04:56:10 2009
New Revision: 71027

Log:
First batch of signature documentation changes; using default argument syntax where applicable.


Modified:
   python/branches/py3k/Doc/library/abc.rst
   python/branches/py3k/Doc/library/aifc.rst
   python/branches/py3k/Doc/library/asynchat.rst
   python/branches/py3k/Doc/library/atexit.rst
   python/branches/py3k/Doc/library/base64.rst
   python/branches/py3k/Doc/library/bdb.rst
   python/branches/py3k/Doc/library/binascii.rst

Modified: python/branches/py3k/Doc/library/abc.rst
==============================================================================
--- python/branches/py3k/Doc/library/abc.rst	(original)
+++ python/branches/py3k/Doc/library/abc.rst	Thu Apr  2 04:56:10 2009
@@ -158,7 +158,7 @@
       multiple-inheritance.
 
 
-.. function:: abstractproperty(fget[, fset[, fdel[, doc]]])
+.. function:: abstractproperty(fget=None, fset=None, fdel=None, doc=None)
 
    A subclass of the built-in :func:`property`, indicating an abstract property.
 

Modified: python/branches/py3k/Doc/library/aifc.rst
==============================================================================
--- python/branches/py3k/Doc/library/aifc.rst	(original)
+++ python/branches/py3k/Doc/library/aifc.rst	Thu Apr  2 04:56:10 2009
@@ -37,7 +37,7 @@
 Module :mod:`aifc` defines the following function:
 
 
-.. function:: open(file[, mode])
+.. function:: open(file, mode=None)
 
    Open an AIFF or AIFF-C file and return an object instance with methods that are
    described below.  The argument *file* is either a string naming a file or a file

Modified: python/branches/py3k/Doc/library/asynchat.rst
==============================================================================
--- python/branches/py3k/Doc/library/asynchat.rst	(original)
+++ python/branches/py3k/Doc/library/asynchat.rst	Thu Apr  2 04:56:10 2009
@@ -202,7 +202,7 @@
 ------------------------------------------
 
 
-.. class:: simple_producer(data[, buffer_size=512])
+.. class:: simple_producer(data, buffer_size=512)
 
    A :class:`simple_producer` takes a chunk of data and an optional buffer
    size.  Repeated calls to its :meth:`more` method yield successive chunks of
@@ -215,7 +215,7 @@
       empty string.
 
 
-.. class:: fifo([list=None])
+.. class:: fifo(list=None)
 
    Each channel maintains a :class:`fifo` holding data which has been pushed
    by the application but not yet popped for writing to the channel.  A

Modified: python/branches/py3k/Doc/library/atexit.rst
==============================================================================
--- python/branches/py3k/Doc/library/atexit.rst	(original)
+++ python/branches/py3k/Doc/library/atexit.rst	Thu Apr  2 04:56:10 2009
@@ -17,7 +17,7 @@
 :func:`os._exit` is called.
 
 
-.. function:: register(func[, *args[, **kargs]])
+.. function:: register(func, *args, **kargs)
 
    Register *func* as a function to be executed at termination.  Any optional
    arguments that are to be passed to *func* must be passed as arguments to
@@ -48,7 +48,8 @@
 .. seealso::
 
    Module :mod:`readline`
-      Useful example of :mod:`atexit` to read and write :mod:`readline` history files.
+      Useful example of :mod:`atexit` to read and write :mod:`readline` history
+      files.
 
 
 .. _atexit-example:

Modified: python/branches/py3k/Doc/library/base64.rst
==============================================================================
--- python/branches/py3k/Doc/library/base64.rst	(original)
+++ python/branches/py3k/Doc/library/base64.rst	Thu Apr  2 04:56:10 2009
@@ -23,7 +23,7 @@
 
 The modern interface provides:
 
-.. function:: b64encode(s[, altchars])
+.. function:: b64encode(s, altchars=None)
 
    Encode a string use Base64.
 
@@ -36,7 +36,7 @@
    The encoded string is returned.
 
 
-.. function:: b64decode(s[, altchars])
+.. function:: b64decode(s, altchars=None)
 
    Decode a Base64 encoded string.
 
@@ -78,7 +78,7 @@
    is returned.
 
 
-.. function:: b32decode(s[, casefold[, map01]])
+.. function:: b32decode(s, casefold=False, map01=None)
 
    Decode a Base32 encoded string.
 
@@ -105,7 +105,7 @@
    *s* is the string to encode.  The encoded string is returned.
 
 
-.. function:: b16decode(s[, casefold])
+.. function:: b16decode(s, casefold=False)
 
    Decode a Base16 encoded string.
 

Modified: python/branches/py3k/Doc/library/bdb.rst
==============================================================================
--- python/branches/py3k/Doc/library/bdb.rst	(original)
+++ python/branches/py3k/Doc/library/bdb.rst	Thu Apr  2 04:56:10 2009
@@ -16,7 +16,7 @@
 
 The :mod:`bdb` module also defines two classes:
 
-.. class:: Breakpoint(self, file, line[, temporary=0[, cond=None [, funcname=None]]])
+.. class:: Breakpoint(self, file, line, temporary=0, cond=None, funcname=None)
 
    This class implements temporary breakpoints, ignore counts, disabling and
    (re-)enabling, and conditionals.
@@ -50,7 +50,7 @@
       Mark the breakpoint as disabled.
 
 
-   .. method:: pprint([out])
+   .. method:: bpprint(out=None)
 
       Print all the information about the breakpoint:
 
@@ -233,7 +233,7 @@
    breakpoints.  These methods return a string containing an error message if
    something went wrong, or ``None`` if all is well.
 
-   .. method:: set_break(filename, lineno[, temporary=0[, cond[, funcname]]])
+   .. method:: set_break(filename, lineno, temporary=0, cond, funcname)
 
       Set a new breakpoint.  If the *lineno* line doesn't exist for the
       *filename* passed as argument, return an error message.  The *filename*
@@ -285,7 +285,7 @@
       Get a list of records for a frame and all higher (calling) and lower
       frames, and the size of the higher part.
 
-   .. method:: format_stack_entry(frame_lineno, [lprefix=': '])
+   .. method:: format_stack_entry(frame_lineno, lprefix=': ')
 
       Return a string with information about a stack entry, identified by a
       ``(frame, lineno)`` tuple:
@@ -300,12 +300,12 @@
    The following two methods can be called by clients to use a debugger to debug
    a :term:`statement`, given as a string.
 
-   .. method:: run(cmd, [globals, [locals]])
+   .. method:: run(cmd, globals=None, locals=None)
 
       Debug a statement executed via the :func:`exec` function.  *globals*
       defaults to :attr:`__main__.__dict__`, *locals* defaults to *globals*.
 
-   .. method:: runeval(expr, [globals, [locals]])
+   .. method:: runeval(expr, globals=None, locals=None)
 
       Debug an expression executed via the :func:`eval` function.  *globals* and
       *locals* have the same meaning as in :meth:`run`.

Modified: python/branches/py3k/Doc/library/binascii.rst
==============================================================================
--- python/branches/py3k/Doc/library/binascii.rst	(original)
+++ python/branches/py3k/Doc/library/binascii.rst	Thu Apr  2 04:56:10 2009
@@ -49,14 +49,14 @@
    should be at most 57 to adhere to the base64 standard.
 
 
-.. function:: a2b_qp(string[, header])
+.. function:: a2b_qp(string, header=False)
 
    Convert a block of quoted-printable data back to binary and return the binary
    data. More than one line may be passed at a time. If the optional argument
    *header* is present and true, underscores will be decoded as spaces.
 
 
-.. function:: b2a_qp(data[, quotetabs, istext, header])
+.. function:: b2a_qp(data, quotetabs=False, istext=True, header=False)
 
    Convert binary data to a line(s) of ASCII characters in quoted-printable
    encoding.  The return value is the converted line(s). If the optional argument


More information about the Python-checkins mailing list