https://github.com/python/cpython/commit/9e5ca3a411875b9557a1132720551f79d0ac8553
commit: 9e5ca3a411875b9557a1132720551f79d0ac8553
branch: 3.14
author: Miss Islington (bot) <[email protected]>
committer: hugovk <[email protected]>
date: 2025-08-27T16:59:47+03:00
summary:

[3.14] gh-138011: Clarify tutorial method object example code (GH-138014) 
(#138025)

Co-authored-by: Terry Jan Reedy <[email protected]>

files:
M Doc/tutorial/classes.rst

diff --git a/Doc/tutorial/classes.rst b/Doc/tutorial/classes.rst
index 9d0fab8861d2a9..645acdf20fb580 100644
--- a/Doc/tutorial/classes.rst
+++ b/Doc/tutorial/classes.rst
@@ -359,7 +359,7 @@ Usually, a method is called right after it is bound::
 
    x.f()
 
-In the :class:`!MyClass` example, this will return the string ``'hello 
world'``.
+If ``x = MyClass()``, as above, this will return the string ``'hello world'``.
 However, it is not necessary to call a method right away: ``x.f`` is a method
 object, and can be stored away and called at a later time.  For example::
 

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]

Reply via email to