On Jul 14, 2013, at 06:11 PM, Nick Coghlan wrote:

>Private interfaces

PEP 8 does say:

    _single_leading_underscore: weak "internal use" indicator. E.g. from M
    import * does not import objects whose name starts with an underscore.

I'm in favor of making this a stronger recommendation, but I have a small
semantic quibble.  Instead of "private interface" it should be "non-public
interface".  The two aren't quite the same thing; for example, often
single-leading underscores are used for methods that subclasses are supposed
to override, e.g. akin to "protected" in C++.

Besides, Python doesn't really have any strong notion of privateness, so
saying "non-public" means "just because you can, doesn't mean you should".

-Barry
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to