diff --git a/Doc/c-api/time.rst b/Doc/c-api/time.rst index 562f0f57262c56c..e9bf9ec101ec7fe 100644 --- a/Doc/c-api/time.rst +++ b/Doc/c-api/time.rst @@ -22,7 +22,7 @@ range is around [-292.3 years; +292.3 years]. Using the Unix epoch (January Time formats: * Seconds. -* Seconds as a floating pointer number (C :c:type:`double`). +* Seconds as a floating pointer number (C :c:expr:`double`). * Milliseconds (10\ :sup:`-3` seconds). * Microseconds (10\ :sup:`-6` seconds). * 100 nanoseconds (10\ :sup:`-7` seconds), used on Windows. @@ -88,7 +88,7 @@ Functions .. c:function:: double PyTime_AsSecondsDouble(PyTime_t t) - Convert a timestamp to a number of seconds as a C :c:type:`double`. + Convert a timestamp to a number of seconds as a C :c:expr:`double`. The function cannot fail. diff --git a/Doc/conf.py b/Doc/conf.py index 7e374fd1a9e97a3..a4a79d8c4d3a1df 100644 --- a/Doc/conf.py +++ b/Doc/conf.py @@ -237,12 +237,12 @@ ('py:meth', '_SubParsersAction.add_parser'), ] -# gh-106948: Copy standard C types declared in the "c:type" domain to the -# "c:identifier" domain, since "c:function" markup looks for types in the -# "c:identifier" domain. Use list() to not iterate on items which are being -# added +# gh-106948: Copy standard C types declared in the "c:type" domain and C +# structures declared in the "c:struct" domain to the "c:identifier" domain, +# since "c:function" markup looks for types in the "c:identifier" domain. Use +# list() to not iterate on items which are being added for role, name in list(nitpick_ignore): - if role == 'c:type': + if role in ('c:type', 'c:struct'): nitpick_ignore.append(('c:identifier', name)) del role, name