From: rurpy on
On Jun 30, 9:42 am, Michele Simionato <michele.simion...(a)gmail.com>
wrote:

> Actually when debugging I use pdb which uses "p" (no parens) for
> printing, so having
> print or print() would not make any difference for me.

Perhaps you don't use CJK strings much?
p u'\u30d1\u30a4\u30c8\u30f3' give quite a different
result than
print u'\u30d1\u30a4\u30c8\u30f3'
at least in python2. Is this different in python3?
From: rantingrick on
On Jun 30, 4:21 pm, geremy condra <debat...(a)gmail.com> wrote:

> Actually, I agree with this complaint though- it is much easier to type
> spaces than parens.

Oh Geremy please. If you're going to whine about something at least
find something worth whining about! Yes a few more key strokes are
needed. But print should have been a function from day one. The
benefits of a print function over a print statement are obvious to
those who seek the truth and lost on those who wallow in self pity. If
it's that much trouble for you then pick up an editor that auto
inserts parenthesis for you, or *gasps* write a routine yourself. Look
i know masturbation makes you lazy, but geez!
From: geremy condra on
On Wed, Jun 30, 2010 at 8:25 PM, rantingrick <rantingrick(a)gmail.com> wrote:
> On Jun 30, 4:21 pm, geremy condra <debat...(a)gmail.com> wrote:
>
>> Actually, I agree with this complaint though- it is much easier to type
>> spaces than parens.
>
> Oh Geremy please. If you're going to whine about something at least
> find something worth whining about! Yes a few more key strokes are
> needed. But print should have been a function from day one. The
> benefits of a print function over a print statement are obvious to
> those who seek the truth and lost on those who wallow in self pity. If
> it's that much trouble for you then pick up an editor that auto
> inserts parenthesis for you, or *gasps* write a routine yourself. Look
> i know masturbation makes you lazy, but geez!

Eh, 3 troll points out of 10. Bonus awarded for the gratuitous sexual
reference, but the deductions for lack of finesse more than overcame
it. Some suggestions for next time:

* use proper punctuation- it lends your posts an air of seriousness.
* use the weakest arguments presented- it infuriates those who
support the position you're trolling from as well.
* overly dramatic statements are a dead giveaway.

Better luck next time.

Geremy Condra
From: John Nagle on
On 6/27/2010 1:09 PM, Martin v. Loewis wrote:
>> I agree that there may be not much reason to port custom proprietary
>> apps that are working fine and which would hardly benefit from, let
>> alone need, and new Py3 features.
>
> In the long run, there will be a benefit: at some point in the future
> (surely years from now), /usr/bin/python will be Python 3.

I'd argue that the name of Python 3 should be consistently
be "python3" in distributions. Python versions are going to have to
coexist for most of the next decade, and this will avoid
confusion.

The 10th anniversary of the announcement of PERL 6 is coming
up on July 19th, and it still hasn't displaced PERL 5 as the
"primary" version.

John Nagle
From: Steven D'Aprano on
On Wed, 30 Jun 2010 18:57:58 -0400, geremy condra wrote:

>>> Actually, I agree with this complaint though- it is much easier to
>>> type spaces than parens.
>>
>> Yes. And typing "p" is easier than typing "print". Perhaps we should
>> replace all Python built-ins with one letter names so that we can
>> *really* optimize our typing effort?
[...]
>> Perhaps not.
>>
>> The rule against premature optimization doesn't just apply to *code*.
>
> Hypocrite. You just took Jorgen Grahn to task in another thread for
> slaying exactly this kind of strawman. You're too smart to think that
> this is what I was advocating.

You're correct, I didn't think that's what *you* were advocating, and I'm
sorry if that's the impression I gave. I agreed with you that typing
"print space args" is easier than "print left-paren args right-parens",
but then took that micro-optimization to its (il)logical conclusion, and
demonstrated that trying to minimize typing effort is a mug's game. You
might call it a strawman, but I prefer to call it reductio ad absurdum.

(That's not to say that we should *maximize* typing either.)

Consistency, expressiveness, readability and re-usability are at least as
important as minimizing typing, and probably more so. The micro-cost of
typing print-as-a-function over print-as-a-statement is, I believe, far
outweighed by the other advantages.

But like all optimizations, measure measure measure. If it turns out that
adding parentheses to print really does add a significant drain on
programmer productivity, then removing them again would no longer be a
premature micro-optimization but an actual optimization.

But, honestly, is there anyone here, even the most heavy users of print,
who would seriously expect that adding parentheses to print calls will do
more than add a tiny fraction to the amount of typing effort already
required to use Python? I suppose in principle those extra three key
presses (shift-9 shift-0 vs space) could be the straw that breaks the
camel's back, but I doubt it.



--
Steven