[Python-checkins] r80069 - python/trunk/Doc/library/os.rst

georg.brandl python-checkins at python.org
Wed Apr 14 15:50:31 CEST 2010


Author: georg.brandl
Date: Wed Apr 14 15:50:31 2010
New Revision: 80069

Log:
Add an x-ref to where the O_ constants are documented and move the SEEK_ constants after lseek().

Modified:
   python/trunk/Doc/library/os.rst

Modified: python/trunk/Doc/library/os.rst
==============================================================================
--- python/trunk/Doc/library/os.rst	(original)
+++ python/trunk/Doc/library/os.rst	Wed Apr 14 15:50:31 2010
@@ -643,6 +643,16 @@
    the file. Availability: Unix, Windows.
 
 
+.. data:: SEEK_SET
+          SEEK_CUR
+          SEEK_END
+
+   Parameters to the :func:`lseek` function. Their values are 0, 1, and 2,
+   respectively. Availability: Windows, Unix.
+
+   .. versionadded:: 2.5
+
+
 .. function:: open(file, flags[, mode])
 
    Open the file *file* and set various flags according to *flags* and possibly its
@@ -652,7 +662,7 @@
 
    For a description of the flag and mode values, see the C run-time documentation;
    flag constants (like :const:`O_RDONLY` and :const:`O_WRONLY`) are defined in
-   this module too (see below).
+   this module too (see :ref:`open-constants`).
 
    .. note::
 
@@ -725,6 +735,12 @@
       :func:`fdopen`, or :data:`sys.stdout` or :data:`sys.stderr`, use its
       :meth:`~file.write` method.
 
+
+.. _open-constants:
+
+``open()`` flag constants
+~~~~~~~~~~~~~~~~~~~~~~~~~
+
 The following constants are options for the *flags* parameter to the
 :func:`~os.open` function.  They can be combined using the bitwise OR operator
 ``|``.  Some of them are not available on all platforms.  For descriptions of
@@ -776,16 +792,6 @@
    the C library.
 
 
-.. data:: SEEK_SET
-          SEEK_CUR
-          SEEK_END
-
-   Parameters to the :func:`lseek` function. Their values are 0, 1, and 2,
-   respectively. Availability: Windows, Unix.
-
-   .. versionadded:: 2.5
-
-
 .. _os-file-dir:
 
 Files and Directories


More information about the Python-checkins mailing list