[Python-3000] print() parameters in py3k
Guido van Rossum
guido at python.org
Mon Nov 20 03:03:32 CET 2006
On 11/19/06, Brett Cannon <brett at python.org> wrote:
> On 11/19/06, Georg Brandl <g.brandl at gmx.net> wrote:
> > Guido van Rossum wrote:
> > > PEPs aren't only for difficult discussions. :-) They are also there
> > > for reference and to record agreement. Referring to an email isn't
> > > really a very good answer when someone asks (as happened here) "what
> > > is the spec"? A PEP may also discourage attempts to add more cruft,
> > > and encourage someone with a few spare cycles to provide a patch so we
> > > can put the whole thing behind it.
> > >
> > > BTW I forgot to mention that it shouldn't return anything.
> > >
> > > (So are you going to write that PEP? :-)
> > It's in Subversion and numbered 3105, should be online with the next
> > website update cycle.
> The only thing I would prefer is instead of 'end' have 'newline' and have
> that be a boolean since I don't see a need to support different line
> endings. I realize the difference between ``end=''`` and ``newline=False``
> is minimal beyond more typing, but for some reason my head just keeps
> telling me I prefer the latter for clarity reasons.
> Otherwise +1 from me.
Oh, but I *do* see a use case for other line endings. E.g. when
writing a Windows file or a standards-compliant email from within
Unix, end="\r\n" would be helpful. In practice it probably would be a
variable set from a config option.
--Guido van Rossum (home page: http://www.python.org/~guido/)
More information about the Python-3000