mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
Docs: fix dunders with too many underscores (#103955)
This commit is contained in:
parent
d50f01ad0a
commit
2cf945bec6
2 changed files with 2 additions and 2 deletions
|
@ -1145,7 +1145,7 @@ and :c:type:`PyType_Type` effectively act as defaults.)
|
||||||
|
|
||||||
.. data:: Py_TPFLAGS_MANAGED_DICT
|
.. data:: Py_TPFLAGS_MANAGED_DICT
|
||||||
|
|
||||||
This bit indicates that instances of the class have a ``__dict___``
|
This bit indicates that instances of the class have a ``__dict__``
|
||||||
attribute, and that the space for the dictionary is managed by the VM.
|
attribute, and that the space for the dictionary is managed by the VM.
|
||||||
|
|
||||||
If this flag is set, :const:`Py_TPFLAGS_HAVE_GC` should also be set.
|
If this flag is set, :const:`Py_TPFLAGS_HAVE_GC` should also be set.
|
||||||
|
|
|
@ -124,7 +124,7 @@ This is where using the ``if __name__ == '__main__'`` code block comes in
|
||||||
handy. Code within this block won't run unless the module is executed in the
|
handy. Code within this block won't run unless the module is executed in the
|
||||||
top-level environment.
|
top-level environment.
|
||||||
|
|
||||||
Putting as few statements as possible in the block below ``if __name___ ==
|
Putting as few statements as possible in the block below ``if __name__ ==
|
||||||
'__main__'`` can improve code clarity and correctness. Most often, a function
|
'__main__'`` can improve code clarity and correctness. Most often, a function
|
||||||
named ``main`` encapsulates the program's primary behavior::
|
named ``main`` encapsulates the program's primary behavior::
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue