On 12 Nov 2013 20:15, "Andrew Barnert" <abarnert@yahoo.com> wrote:
> On Nov 11, 2013, at 19:45, Xuancong Wang <xuancong84@gmail.com> wrote:
> > Another suggestion is that 'enumerate' is also frequently used, hopefully we can shorten the command as well.
> One huge advantage of everything being regular functions is that it's ridiculously easy to experiment with this. Want to see what it's like to use "en" or "ix" or whatever instead of enumerate? Just do "en = enumerate", and you can start using it. See how it affects your typing speed, and the readability of your code. (Obviously it will make your code less readable to the general Python community, but ignore that; the interesting question is whether you--or, better, a small group you work in--find it readable once you get used to it).
> Meanwhile, I personally vastly prefer print as a function to a statement. I can pass print to a function instead of having to write an out-of-line wrapper with def. I can do quick joining without spaces, and no-newline-ing without having to mess with magic commas. But then, like most of the others who prefer print as a function, I don't actually use it nearly as much as the people who are complaining, so maybe that doesn't mean much.

A few months ago I came up with a working "call statement" implementation that would allow the parens to be omitted from all simple calls, not just print: http://bugs.python.org/issue18788

That shows such an approach is technically feasible, but it also makes it clear there are major readability issues if the LHS is allowed to be an arbitrary expression.

I'm still vaguely curious what a full PEP for 3.5 (with a suitably constrained LHS) might look like, but I'm not interested enough to write it myself.


> _______________________________________________
> Python-ideas mailing list
> Python-ideas@python.org
> https://mail.python.org/mailman/listinfo/python-ideas