On Apr 13, 7:23 pm, Roy Smith <[EMAIL PROTECTED]> wrote:
> In article
> <[EMAIL PROTECTED]>,
>
>  Lie <[EMAIL PROTECTED]> wrote:
> >  I wish py3k
> > would make it an option whether to treat print as statement or
> > function though.
>
> Arrrgghhhhh!  No, don't even go there.  If you want optional parens, use
> Perl :-)

Not optional parens, but a simple print statement coupled with a
powerful print function. This print statement would only have basic
printing functionality such as :

print "Hello"
print var
print var, "Hello too"

specifically, these would be removed:
print var,
print >> unstdout, var

This is because it is sometimes annoying to type this:
print("Hello")
print("World")
print("This")
print("is")
print("Captain")
print("Kirk")

because of the double enclosement (parens () and quotes ""),
especially when you're just slipping a simple debugging statement.

This also eases transition between older codes, because while you uses
regular print statements everyday, you don't do print redirection and
comma-ended printing everyday, and it would be easier to just convert
those advanced printing functionality rather than converting all
printing statements.
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to