[Python-Dev] PEP 259: Omit printing newline after newline

Alex Martelli aleaxit at yahoo.com
Tue Jun 12 14:40:04 CEST 2001


"Roman Suzi" <rnd at onego.ru> wrote in message
news:mailman.992345118.22375.python-list at python.org...
    ...
> >That one is: print.  A keyword statement that neither
>
> May be allow to call functions as statements then?
> Then there will be no difference:

There are languages that wipe out any difference between
statements and expressions (including function calls).

Python is definitely *NOT* one of those.  Expressions
can be used as statements (which occasionally causes a
few problems, too:-), but not vice versa.  It's highly
unlikely that Python will ever change so deeply as to
heal THIS 'split' -- particularly since it is not
generally perceived as a problem:-).


> write file, "this is line"
>
> Oh... It will be Tcl then...

Visual Basic 6 used to have this idea (that you could
do without the parentheses in a subroutine call), but
VB is losing it in the move to VB .NET (one of many
incompatible changes to VB in the 6->.NET migration --
ALL of the changes take VB slightly closer to Python,
in syntax and/or semantics, as I mentioned in a post
a few days ago).

Would you really like to have to invent a new set
of rules to distinguish whether
    pow(2,3),4
(a 2-element tuple (8,4)) or
    pow(2,3,4)
(integer 0) is meant when one writes
    pow 2, 3, 4
...?-)  Perl has enough trouble with that one, I
think.  Simple, regular use of parentheses for any
function call is one of the many aspects that make
Python syntax simpler and more effective.


Alex






More information about the Python-list mailing list