On 10/09/2013 08:09 AM, Larry Hastings wrote:
On 10/09/2013 04:45 PM, Anders J. Munch wrote:

How about a naming convention instead, where using a leading
underscore in a parameter name is a hint that it is positional-only.

For example, the docstring of sorted:

    sorted(iterable, key=None, reverse=False) --> new sorted list

would become:

    sorted(_iterable, key=None, reverse=False) --> new sorted list

In any case, boy am I -1 on this.  If you wish to continue this proposal 
further please write your own PEP.

A leading underscore indicates a private implementation detail. The proposed signature now looks like we can provide a key and reverse, but only riskily provide the actual thing we want sorted. No warm fuzzy feelings there! ;)

-1

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

Reply via email to