Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit df48b97

Browse files
committed
Fix a few scoping issues with versionadded/versionchanged directives.
1 parent 645d3b7 commit df48b97

12 files changed

Lines changed: 38 additions & 32 deletions

Doc/c-api/exceptions.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ in various ways. There is a separate error indicator for each thread.
247247
filename object, for raising errors when a function that takes two filenames
248248
fails.
249249
250-
.. versionadded:: 3.4
250+
.. versionadded:: 3.4
251251
252252
253253
.. c:function:: PyObject* PyErr_SetFromErrnoWithFilename(PyObject *type, const char *filename)
@@ -295,7 +295,7 @@ in various ways. There is a separate error indicator for each thread.
295295
but accepts a second filename object.
296296
Availability: Windows.
297297
298-
.. versionadded:: 3.4
298+
.. versionadded:: 3.4
299299
300300
301301
.. c:function:: PyObject* PyErr_SetExcFromWindowsErrWithFilename(PyObject *type, int ierr, const char *filename)
@@ -321,15 +321,15 @@ in various ways. There is a separate error indicator for each thread.
321321
attributes, which make the exception printing subsystem think the exception
322322
is a :exc:`SyntaxError`.
323323
324-
.. versionadded:: 3.4
324+
.. versionadded:: 3.4
325325
326326
327327
.. c:function:: void PyErr_SyntaxLocationEx(char *filename, int lineno, int col_offset)
328328
329329
Like :c:func:`PyErr_SyntaxLocationObject`, but *filename* is a byte string
330330
decoded from the filesystem encoding (:func:`os.fsdecode`).
331331
332-
.. versionadded:: 3.2
332+
.. versionadded:: 3.2
333333
334334
335335
.. c:function:: void PyErr_SyntaxLocation(char *filename, int lineno)

Doc/c-api/object.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -364,6 +364,7 @@ attribute is considered sufficient for this determination.
364364
365365
.. versionadded:: 3.4
366366
367+
367368
.. c:function:: PyObject* PyObject_GetItem(PyObject *o, PyObject *key)
368369
369370
Return element of *o* corresponding to the object *key* or *NULL* on failure.

Doc/library/doctest.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -502,7 +502,8 @@ or'ed together and passed to various functions. The names can also be used in
502502
:ref:`doctest directives <doctest-directives>`, and may be passed to the
503503
doctest command line interface via the ``-o`` option.
504504

505-
.. versionadded:: 3.4 the ``-o`` command line option
505+
.. versionadded:: 3.4
506+
The ``-o`` command line option.
506507

507508
The first group of options define test semantics, controlling aspects of how
508509
doctest decides whether actual output matches an example's expected output:

Doc/library/faulthandler.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
.. module:: faulthandler
55
:synopsis: Dump the Python traceback.
66

7+
.. versionadded:: 3.3
8+
79
This module contains functions to dump Python tracebacks explicitly, on a fault,
810
after a timeout, or on a user signal. Call :func:`faulthandler.enable` to
911
install fault handlers for the :const:`SIGSEGV`, :const:`SIGFPE`,
@@ -36,8 +38,6 @@ alternatively be passed to :func:`faulthandler.enable`.
3638
The module is implemented in C, so tracebacks can be dumped on a crash or when
3739
Python is deadlocked.
3840

39-
.. versionadded:: 3.3
40-
4141

4242
Dump the traceback
4343
------------------

Doc/library/functions.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -832,6 +832,7 @@ are always available. They are listed here in alphabetical order.
832832
.. versionadded:: 3.4
833833
The *default* keyword-only argument.
834834

835+
835836
.. function:: next(iterator[, default])
836837

837838
Retrieve the next item from the *iterator* by calling its

Doc/library/imaplib.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -451,6 +451,7 @@ An :class:`IMAP4` instance has the following methods:
451451
:attr:`ssl.SSLContext.check_hostname` and *Server Name Indication* (see
452452
:data:`ssl.HAS_SNI`).
453453

454+
454455
.. method:: IMAP4.status(mailbox, names)
455456

456457
Request named status conditions for *mailbox*.

Doc/library/imp.rst

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -262,12 +262,12 @@ that circular imports work without any deadlocks.
262262
exception is made for circular imports, which by construction have to
263263
expose an incomplete module object at some point.
264264

265-
.. versionchanged:: 3.3
266-
The locking scheme has changed to per-module locks for
267-
the most part. A global import lock is kept for some critical tasks,
268-
such as initializing the per-module locks.
265+
.. versionchanged:: 3.3
266+
The locking scheme has changed to per-module locks for
267+
the most part. A global import lock is kept for some critical tasks,
268+
such as initializing the per-module locks.
269269

270-
.. deprecated:: 3.4
270+
.. deprecated:: 3.4
271271

272272

273273
.. function:: acquire_lock()
@@ -282,25 +282,25 @@ that circular imports work without any deadlocks.
282282

283283
On platforms without threads, this function does nothing.
284284

285-
.. versionchanged:: 3.3
286-
The locking scheme has changed to per-module locks for
287-
the most part. A global import lock is kept for some critical tasks,
288-
such as initializing the per-module locks.
285+
.. versionchanged:: 3.3
286+
The locking scheme has changed to per-module locks for
287+
the most part. A global import lock is kept for some critical tasks,
288+
such as initializing the per-module locks.
289289

290-
.. deprecated:: 3.4
290+
.. deprecated:: 3.4
291291

292292

293293
.. function:: release_lock()
294294

295295
Release the interpreter's global import lock. On platforms without
296296
threads, this function does nothing.
297297

298-
.. versionchanged:: 3.3
299-
The locking scheme has changed to per-module locks for
300-
the most part. A global import lock is kept for some critical tasks,
301-
such as initializing the per-module locks.
298+
.. versionchanged:: 3.3
299+
The locking scheme has changed to per-module locks for
300+
the most part. A global import lock is kept for some critical tasks,
301+
such as initializing the per-module locks.
302302

303-
.. deprecated:: 3.4
303+
.. deprecated:: 3.4
304304

305305

306306
The following constants with integer values, defined in this module, are used

Doc/library/importlib.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -626,8 +626,8 @@ ABC hierarchy::
626626
have to implement it, but it is still available for compatibility
627627
purposes. Raise :exc:`IOError` if the path cannot be handled.
628628

629-
.. versionchanged:: 3.4
630-
Raise :exc:`IOError` instead of :exc:`NotImplementedError`.
629+
.. versionchanged:: 3.4
630+
Raise :exc:`IOError` instead of :exc:`NotImplementedError`.
631631

632632
.. method:: set_data(path, data)
633633

Doc/library/multiprocessing.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,9 +138,9 @@ to start a process. These *start methods* are
138138

139139
.. versionchanged:: 3.4
140140
*spawn* added on all unix platforms, and *forkserver* added for
141-
some unix platforms.
141+
some unix platforms.
142142
Child processes no longer inherit all of the parents inheritable
143-
handles on Windows.
143+
handles on Windows.
144144

145145
On Unix using the *spawn* or *forkserver* start methods will also
146146
start a *semaphore tracker* process which tracks the unlinked named

Doc/library/optparse.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88
.. sectionauthor:: Greg Ward <[email protected]>
99

1010
.. deprecated:: 3.2
11-
The :mod:`optparse` module is deprecated and will not be developed further;
12-
development will continue with the :mod:`argparse` module.
11+
The :mod:`optparse` module is deprecated and will not be developed further;
12+
development will continue with the :mod:`argparse` module.
1313

1414
**Source code:** :source:`Lib/optparse.py`
1515

0 commit comments

Comments
 (0)