[Python-checkins] cpython (merge 3.5 -> 3.6): Merge: #29005: clarify terminology in tutorial 'method' discussion.

r.david.murray python-checkins at python.org
Sun Dec 18 15:02:59 EST 2016


https://hg.python.org/cpython/rev/7314e08dc907
changeset: 105728:7314e08dc907
branch: 3.6
parent: 105724:a46a20a1f286
parent: 105727:6f89f5eb4422
user: R David Murray <rdmurray at bitdance.com>
date: Sun Dec 18 15:00:23 2016 -0500
summary:
 Merge: #29005: clarify terminology in tutorial 'method' discussion.
files:
 Doc/tutorial/classes.rst | 5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/Doc/tutorial/classes.rst b/Doc/tutorial/classes.rst
--- a/Doc/tutorial/classes.rst
+++ b/Doc/tutorial/classes.rst
@@ -374,11 +374,11 @@
 called without any --- even if the argument isn't actually used...
 
 Actually, you may have guessed the answer: the special thing about methods is
-that the object is passed as the first argument of the function. In our
+that the instance object is passed as the first argument of the function. In our
 example, the call ``x.f()`` is exactly equivalent to ``MyClass.f(x)``. In
 general, calling a method with a list of *n* arguments is equivalent to calling
 the corresponding function with an argument list that is created by inserting
-the method's object before the first argument.
+the method's instance object before the first argument.
 
 If you still don't understand how methods work, a look at the implementation can
 perhaps clarify matters. When an instance attribute is referenced that isn't a
@@ -906,4 +906,3 @@
 namespace; the name :attr:`~object.__dict__` is an attribute but not a global name.
 Obviously, using this violates the abstraction of namespace implementation, and
 should be restricted to things like post-mortem debuggers.
-
-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /