mirror of
https://github.com/python/cpython.git
synced 2026-02-05 17:35:34 +00:00
Merge 3e31bd07e5 into b6d8aa436b
This commit is contained in:
commit
693de647f0
1 changed files with 1 additions and 1 deletions
|
|
@ -344,7 +344,7 @@ function that "belongs to" an object.
|
|||
|
||||
Valid method names of an instance object depend on its class. By definition,
|
||||
all attributes of a class that are function objects define corresponding
|
||||
methods of its instances. So in our example, ``x.f`` is a valid method
|
||||
methods of its instances. So in our :ref:`previous example <tut-classobjects>`, ``x.f`` is a valid method
|
||||
reference, since ``MyClass.f`` is a function, but ``x.i`` is not, since
|
||||
``MyClass.i`` is not. But ``x.f`` is not the same thing as ``MyClass.f`` --- it
|
||||
is a *method object*, not a function object.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue