File tree Expand file tree Collapse file tree 4 files changed +4
-4
lines changed Expand file tree Collapse file tree 4 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -572,7 +572,7 @@ and :c:data:`PyType_Type` effectively act as defaults.)
572572 :attr: `~type.__name__ ` attribute.
573573
574574 If no dot is present, the entire :c:member: `~PyTypeObject.tp_name ` field is made accessible as the
575- :attr: `~type.__name__ ` attribute, and the :attr: `~class .__module__ ` attribute is undefined
575+ :attr: `~type.__name__ ` attribute, and the :attr: `~type .__module__ ` attribute is undefined
576576 (unless explicitly set in the dictionary, as explained above). This means your
577577 type will be impossible to pickle. Additionally, it will not be listed in
578578 module documentations created with pydoc.
Original file line number Diff line number Diff line change @@ -953,7 +953,7 @@ a given class::
953953 unpickled_class = pickle.loads(f.getvalue())
954954
955955 assert isinstance(unpickled_class, type)
956- assert unpickled_type .__name__ == "MyClass"
956+ assert unpickled_class .__name__ == "MyClass"
957957 assert unpickled_class.my_attribute == 1
958958
959959
Original file line number Diff line number Diff line change @@ -2597,7 +2597,7 @@ Preparing the class namespace
25972597
25982598Once the appropriate metaclass has been identified, then the class namespace
25992599is prepared. If the metaclass has a ``__prepare__ `` attribute, it is called
2600- as ``namespace = metatype .__prepare__(name, bases, **kwds) `` (where the
2600+ as ``namespace = metaclass .__prepare__(name, bases, **kwds) `` (where the
26012601additional keyword arguments, if any, come from the class definition). The
26022602``__prepare__ `` method should be implemented as a
26032603:func: `classmethod <classmethod> `. The
Original file line number Diff line number Diff line change @@ -1113,7 +1113,7 @@ Here are all of the changes that Python 2.3 makes to the core Python language.
11131113 <type '_socket.socket'>
11141114
11151115* One of the noted incompatibilities between old- and new-style classes has been
1116- removed: you can now assign to the :attr: `~type.__name__ ` and :attr: `~class .__bases__ `
1116+ removed: you can now assign to the :attr: `~type.__name__ ` and :attr: `~type .__bases__ `
11171117 attributes of new-style classes. There are some restrictions on what can be
11181118 assigned to :attr: `!__bases__ ` along the lines of those relating to assigning to
11191119 an instance's :attr: `~object.__class__ ` attribute.
You can’t perform that action at this time.
0 commit comments