mirror of
https://github.com/python/cpython.git
synced 2025-09-26 10:19:53 +00:00
[3.12] gh-106892: Use roles :data: and :const: for referencing module variables (GH-106894) (GH-106954)
(cherry picked from commit d036db728e
)
This commit is contained in:
parent
84e52171b5
commit
ffc7678f46
40 changed files with 111 additions and 111 deletions
|
@ -126,9 +126,9 @@ Importing Modules
|
|||
read from a Python bytecode file or obtained from the built-in function
|
||||
:func:`compile`, load the module. Return a new reference to the module object,
|
||||
or ``NULL`` with an exception set if an error occurred. *name*
|
||||
is removed from :attr:`sys.modules` in error cases, even if *name* was already
|
||||
in :attr:`sys.modules` on entry to :c:func:`PyImport_ExecCodeModule`. Leaving
|
||||
incompletely initialized modules in :attr:`sys.modules` is dangerous, as imports of
|
||||
is removed from :data:`sys.modules` in error cases, even if *name* was already
|
||||
in :data:`sys.modules` on entry to :c:func:`PyImport_ExecCodeModule`. Leaving
|
||||
incompletely initialized modules in :data:`sys.modules` is dangerous, as imports of
|
||||
such modules have no way to know that the module object is an unknown (and
|
||||
probably damaged with respect to the module author's intents) state.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue