[Python-ideas] Integrate some itertools into the Python syntax

Alexander Walters tritium-list at sdamon.com
Tue Mar 22 04:39:37 EDT 2016


On 3/22/2016 03:34, Graham Gower wrote:
>
> And consider the other side of the coin. If I read code using a
> function of the itertools module, its easy to look up the definition;
> if I read code featuring a rarely used syntax, how easy is it to come
> up with search engine terms to describe the syntax, and thus find
> documentation for the feature?
>

This is a pure devil's advocate response, as I don't feel there is a 
need to add itertools functionality to the language itself.

Googling for 'Python with keyword' or 'Python lambda keyword', for 
example, give very good results (documentation or examples in the first 
5 results on both).  Any proposal involving adding a new keyword would 
probably be as discoverable as the standard library.

... Which is the big gotcha with arguments involving new keywords. If it 
makes it exactly as discoverable, then nothing is gained by new syntax, 
and we are back where we started.  Your point is accurate for any syntax 
that does not involve new keywords, or for new uses of existing keywords.


More information about the Python-ideas mailing list