summaryrefslogtreecommitdiffstats
path: root/Doc/reference
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2013-04-14 08:13:42 (GMT)
committerGeorg Brandl <georg@python.org>2013-04-14 08:13:42 (GMT)
commitdec3b3f704284ba60b17612ee547c9dee85cc9cd (patch)
tree4236e0923c16bfb8daecebe249f2f93f684c29d2 /Doc/reference
parent6eea8184235cb83807dd96c32ee78eddc83a9dc9 (diff)
downloadcpython-dec3b3f704284ba60b17612ee547c9dee85cc9cd.zip
cpython-dec3b3f704284ba60b17612ee547c9dee85cc9cd.tar.gz
cpython-dec3b3f704284ba60b17612ee547c9dee85cc9cd.tar.bz2
Clarify point in name mangling doc.
Diffstat (limited to 'Doc/reference')
-rw-r--r--Doc/reference/expressions.rst15
1 files changed, 7 insertions, 8 deletions
diff --git a/Doc/reference/expressions.rst b/Doc/reference/expressions.rst
index c866f84..c0132bd 100644
--- a/Doc/reference/expressions.rst
+++ b/Doc/reference/expressions.rst
@@ -84,14 +84,13 @@ exception.
definition begins with two or more underscore characters and does not end in two
or more underscores, it is considered a :dfn:`private name` of that class.
Private names are transformed to a longer form before code is generated for
-them. The transformation inserts the class name in front of the name, with
-leading underscores removed, and a single underscore inserted in front of the
-class name. For example, the identifier ``__spam`` occurring in a class named
-``Ham`` will be transformed to ``_Ham__spam``. This transformation is
-independent of the syntactical context in which the identifier is used. If the
-transformed name is extremely long (longer than 255 characters), implementation
-defined truncation may happen. If the class name consists only of underscores,
-no transformation is done.
+them. The transformation inserts the class name, with leading underscores
+removed and a single underscore inserted, in front of the name. For example,
+the identifier ``__spam`` occurring in a class named ``Ham`` will be transformed
+to ``_Ham__spam``. This transformation is independent of the syntactical
+context in which the identifier is used. If the transformed name is extremely
+long (longer than 255 characters), implementation defined truncation may happen.
+If the class name consists only of underscores, no transformation is done.
.. _atom-literals: