Skip to content

Commit

Permalink
gh-90359: Unify documentation style for datetime.rst (gh-94836)
Browse files Browse the repository at this point in the history
  • Loading branch information
corona10 authored Jul 14, 2022
1 parent 07374cc commit 967da5f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Doc/c-api/datetime.rst
Original file line number Diff line number Diff line change
Expand Up @@ -132,13 +132,15 @@ Macros to create objects:
resulting number of microseconds and seconds lie in the ranges documented for
:class:`datetime.timedelta` objects.
.. c:function:: PyObject* PyTimeZone_FromOffset(PyDateTime_DeltaType* offset)
Return a :class:`datetime.timezone` object with an unnamed fixed offset
represented by the *offset* argument.
.. versionadded:: 3.7
.. c:function:: PyObject* PyTimeZone_FromOffsetAndName(PyDateTime_DeltaType* offset, PyUnicode* name)
Return a :class:`datetime.timezone` object with a fixed offset represented
Expand Down Expand Up @@ -190,18 +192,21 @@ must not be ``NULL``, and the type is not checked:
Return the microsecond, as an int from 0 through 999999.
.. c:function:: int PyDateTime_DATE_GET_FOLD(PyDateTime_DateTime *o)
Return the fold, as an int from 0 through 1.
.. versionadded:: 3.6
.. c:function:: PyObject* PyDateTime_DATE_GET_TZINFO(PyDateTime_DateTime *o)
Return the tzinfo (which may be ``None``).
.. versionadded:: 3.10
Macros to extract fields from time objects. The argument must be an instance of
:c:data:`PyDateTime_Time`, including subclasses. The argument must not be ``NULL``,
and the type is not checked:
Expand All @@ -225,12 +230,14 @@ and the type is not checked:
Return the microsecond, as an int from 0 through 999999.
.. c:function:: int PyDateTime_TIME_GET_FOLD(PyDateTime_Time *o)
Return the fold, as an int from 0 through 1.
.. versionadded:: 3.6
.. c:function:: PyObject* PyDateTime_TIME_GET_TZINFO(PyDateTime_Time *o)
Return the tzinfo (which may be ``None``).
Expand Down

0 comments on commit 967da5f

Please sign in to comment.