summaryrefslogtreecommitdiffstats
path: root/Doc/tutorial
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2018-11-07 18:30:06 (GMT)
committerGitHub <noreply@github.com>2018-11-07 18:30:06 (GMT)
commita5bd0d3c300e27652fd364a2516ee30d17ba1cf5 (patch)
tree669584d50ae8e730b7efce851db96038eb6ab364 /Doc/tutorial
parent0d9896db1638e924a4215772ffc0251e16304b9f (diff)
downloadcpython-a5bd0d3c300e27652fd364a2516ee30d17ba1cf5.zip
cpython-a5bd0d3c300e27652fd364a2516ee30d17ba1cf5.tar.gz
cpython-a5bd0d3c300e27652fd364a2516ee30d17ba1cf5.tar.bz2
Add a reference to the name mangling description in the tutorial to the index. (GH-10138)
(cherry picked from commit c5eec4426d9144b2255500217d0e3ff9463d2770) Co-authored-by: Andrés Delfino <adelfino@gmail.com>
Diffstat (limited to 'Doc/tutorial')
-rw-r--r--Doc/tutorial/classes.rst3
1 files changed, 3 insertions, 0 deletions
diff --git a/Doc/tutorial/classes.rst b/Doc/tutorial/classes.rst
index 487d535..914da42 100644
--- a/Doc/tutorial/classes.rst
+++ b/Doc/tutorial/classes.rst
@@ -672,6 +672,9 @@ be treated as a non-public part of the API (whether it is a function, a method
or a data member). It should be considered an implementation detail and subject
to change without notice.
+.. index::
+ pair: name; mangling
+
Since there is a valid use-case for class-private members (namely to avoid name
clashes of names with names defined by subclasses), there is limited support for
such a mechanism, called :dfn:`name mangling`. Any identifier of the form