Skip to content

Commit b90e3ea

Browse files
committed
Address Abby's docs comment.
1 parent eaf8335 commit b90e3ea

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

Doc/reference/simple_stmts.rst

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -882,25 +882,25 @@ Lazy imports
882882
pair: lazy; import
883883
single: lazy import
884884

885-
The :keyword:`lazy` keyword marks an import as lazy. It is a :ref:`soft keyword
886-
<soft-keywords>` that only has special meaning when it appears immediately
887-
before an :keyword:`import` or :keyword:`from` statement.
888-
889-
When an import statement is preceded by the :keyword:`lazy` keyword,
890-
the import becomes *lazy*: the module is not loaded immediately at the import
891-
statement. Instead, a lazy proxy object is created and bound to the name. The
892-
actual module is loaded on first use of that name.
893-
894-
Lazy imports are only permitted at module scope. Using ``lazy`` inside a
895-
function, class body, or :keyword:`try`/:keyword:`except`/:keyword:`finally`
896-
block raises a :exc:`SyntaxError`. Star imports cannot be lazy (``lazy from
897-
module import *`` is a syntax error), and :ref:`future statements <future>`
898-
cannot be lazy.
885+
The :keyword:`lazy` keyword is a :ref:`soft keyword <soft-keywords>` that
886+
only has special meaning when it appears immediately before an
887+
:keyword:`import` or :keyword:`from` statement. When an import statement is
888+
preceded by the :keyword:`lazy` keyword, the import becomes *lazy*: the
889+
module is not loaded immediately at the import statement. Instead, a lazy
890+
proxy object is created and bound to the name. The actual module is loaded
891+
on first use of that name.
892+
893+
Lazy imports are only permitted at module scope. Using :keyword:`lazy`
894+
inside a function, class body, or
895+
:keyword:`try`/:keyword:`except`/:keyword:`finally` block raises a
896+
:exc:`SyntaxError`. Star imports cannot be lazy (``lazy from module import
897+
*`` is a syntax error), and :ref:`future statements <future>` cannot be
898+
lazy.
899899

900900
When using ``lazy from ... import``, each imported name is bound to a lazy
901901
proxy object. The first access to any of these names triggers loading of the
902-
entire module and resolves only that specific name to its actual value. Other
903-
names remain as lazy proxies until they are accessed.
902+
entire module and resolves only that specific name to its actual value.
903+
Other names remain as lazy proxies until they are accessed.
904904

905905
Example::
906906

0 commit comments

Comments
 (0)