[issue27793] Double underscore variables in module are mangled when used in class

R. David Murray report at bugs.python.org
Fri Mar 6 16:40:27 EST 2020


R. David Murray <rdmurray at bitdance.com> added the comment:

You are welcome to open a doc-enhancement issue for the global docs.  For the other, as noted already if you want to advocate for a change to this behavior you need to start on python-ideas, but I don't think you will get any traction.

Another possible enhancement you could propose (in a new issue) is to have the global statement check for variables that start with '__' and do something appropriate such as issue a warning...although I don't really know how hard that would be to implement.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue27793>
_______________________________________


More information about the Python-bugs-list mailing list