Ignore:
Timestamp:
Mar 19, 2014, 11:31:01 PM (11 years ago)
Author:
dmik
Message:

python: Merge vendor 2.7.6 to trunk.

Location:
python/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • python/trunk

  • python/trunk/Doc/c-api/sys.rst

    r2 r391  
    77
    88
    9 .. cfunction:: int Py_FdIsInteractive(FILE *fp, const char *filename)
     9.. c:function:: int Py_FdIsInteractive(FILE *fp, const char *filename)
    1010
    1111   Return true (nonzero) if the standard I/O file *fp* with name *filename* is
    1212   deemed interactive.  This is the case for files for which ``isatty(fileno(fp))``
    13    is true.  If the global flag :cdata:`Py_InteractiveFlag` is true, this function
     13   is true.  If the global flag :c:data:`Py_InteractiveFlag` is true, this function
    1414   also returns true if the *filename* pointer is *NULL* or if the name is equal to
    1515   one of the strings ``'<stdin>'`` or ``'???'``.
    1616
    1717
    18 .. cfunction:: long PyOS_GetLastModificationTime(char *filename)
    19 
    20    Return the time of last modification of the file *filename*. The result is
    21    encoded in the same way as the timestamp returned by the standard C library
    22    function :cfunc:`time`.
    23 
    24 
    25 .. cfunction:: void PyOS_AfterFork()
     18.. c:function:: void PyOS_AfterFork()
    2619
    2720   Function to update some internal state after a process fork; this should be
     
    3124
    3225
    33 .. cfunction:: int PyOS_CheckStack()
     26.. c:function:: int PyOS_CheckStack()
    3427
    3528   Return true when the interpreter runs out of stack space.  This is a reliable
     
    4033
    4134
    42 .. cfunction:: PyOS_sighandler_t PyOS_getsig(int i)
     35.. c:function:: PyOS_sighandler_t PyOS_getsig(int i)
    4336
    4437   Return the current signal handler for signal *i*.  This is a thin wrapper around
    45    either :cfunc:`sigaction` or :cfunc:`signal`.  Do not call those functions
    46    directly! :ctype:`PyOS_sighandler_t` is a typedef alias for :ctype:`void
     38   either :c:func:`sigaction` or :c:func:`signal`.  Do not call those functions
     39   directly! :c:type:`PyOS_sighandler_t` is a typedef alias for :c:type:`void
    4740   (\*)(int)`.
    4841
    4942
    50 .. cfunction:: PyOS_sighandler_t PyOS_setsig(int i, PyOS_sighandler_t h)
     43.. c:function:: PyOS_sighandler_t PyOS_setsig(int i, PyOS_sighandler_t h)
    5144
    5245   Set the signal handler for signal *i* to be *h*; return the old signal handler.
    53    This is a thin wrapper around either :cfunc:`sigaction` or :cfunc:`signal`.  Do
    54    not call those functions directly!  :ctype:`PyOS_sighandler_t` is a typedef
    55    alias for :ctype:`void (\*)(int)`.
     46   This is a thin wrapper around either :c:func:`sigaction` or :c:func:`signal`.  Do
     47   not call those functions directly!  :c:type:`PyOS_sighandler_t` is a typedef
     48   alias for :c:type:`void (\*)(int)`.
    5649
    5750.. _systemfunctions:
     
    6457:mod:`sys` module's dict, which is contained in the internal thread state structure.
    6558
    66 .. cfunction:: PyObject *PySys_GetObject(char *name)
     59.. c:function:: PyObject *PySys_GetObject(char *name)
    6760
    6861   Return the object *name* from the :mod:`sys` module or *NULL* if it does
    6962   not exist, without setting an exception.
    7063
    71 .. cfunction:: FILE *PySys_GetFile(char *name, FILE *def)
     64.. c:function:: FILE *PySys_GetFile(char *name, FILE *def)
    7265
    73    Return the :ctype:`FILE*` associated with the object *name* in the
     66   Return the :c:type:`FILE*` associated with the object *name* in the
    7467   :mod:`sys` module, or *def* if *name* is not in the module or is not associated
    75    with a :ctype:`FILE*`.
     68   with a :c:type:`FILE*`.
    7669
    77 .. cfunction:: int PySys_SetObject(char *name, PyObject *v)
     70.. c:function:: int PySys_SetObject(char *name, PyObject *v)
    7871
    7972   Set *name* in the :mod:`sys` module to *v* unless *v* is *NULL*, in which
     
    8174   on error.
    8275
    83 .. cfunction:: void PySys_ResetWarnOptions()
     76.. c:function:: void PySys_ResetWarnOptions()
    8477
    8578   Reset :data:`sys.warnoptions` to an empty list.
    8679
    87 .. cfunction:: void PySys_AddWarnOption(char *s)
     80.. c:function:: void PySys_AddWarnOption(char *s)
    8881
    8982   Append *s* to :data:`sys.warnoptions`.
    9083
    91 .. cfunction:: void PySys_SetPath(char *path)
     84.. c:function:: void PySys_SetPath(char *path)
    9285
    9386   Set :data:`sys.path` to a list object of paths found in *path* which should
     
    9588   (``:`` on Unix, ``;`` on Windows).
    9689
    97 .. cfunction:: void PySys_WriteStdout(const char *format, ...)
     90.. c:function:: void PySys_WriteStdout(const char *format, ...)
    9891
    9992   Write the output string described by *format* to :data:`sys.stdout`.  No
     
    111104   is written to the real (C level) *stdout*.
    112105
    113 .. cfunction:: void PySys_WriteStderr(const char *format, ...)
     106.. c:function:: void PySys_WriteStderr(const char *format, ...)
    114107
    115108   As above, but write to :data:`sys.stderr` or *stderr* instead.
     
    122115
    123116
    124 .. cfunction:: void Py_FatalError(const char *message)
     117.. c:function:: void Py_FatalError(const char *message)
    125118
    126119   .. index:: single: abort()
     
    130123   make it dangerous to continue using the Python interpreter; e.g., when the
    131124   object administration appears to be corrupted.  On Unix, the standard C library
    132    function :cfunc:`abort` is called which will attempt to produce a :file:`core`
     125   function :c:func:`abort` is called which will attempt to produce a :file:`core`
    133126   file.
    134127
    135128
    136 .. cfunction:: void Py_Exit(int status)
     129.. c:function:: void Py_Exit(int status)
    137130
    138131   .. index::
     
    140133      single: exit()
    141134
    142    Exit the current process.  This calls :cfunc:`Py_Finalize` and then calls the
     135   Exit the current process.  This calls :c:func:`Py_Finalize` and then calls the
    143136   standard C library function ``exit(status)``.
    144137
    145138
    146 .. cfunction:: int Py_AtExit(void (*func) ())
     139.. c:function:: int Py_AtExit(void (*func) ())
    147140
    148141   .. index::
     
    150143      single: cleanup functions
    151144
    152    Register a cleanup function to be called by :cfunc:`Py_Finalize`.  The cleanup
     145   Register a cleanup function to be called by :c:func:`Py_Finalize`.  The cleanup
    153146   function will be called with no arguments and should return no value.  At most
    154147   32 cleanup functions can be registered.  When the registration is successful,
    155    :cfunc:`Py_AtExit` returns ``0``; on failure, it returns ``-1``.  The cleanup
     148   :c:func:`Py_AtExit` returns ``0``; on failure, it returns ``-1``.  The cleanup
    156149   function registered last is called first. Each cleanup function will be called
    157150   at most once.  Since Python's internal finalization will have completed before
Note: See TracChangeset for help on using the changeset viewer.