Re: string formatting documentation

2009-01-19 Thread Alan G Isaac
On 1/19/2009 5:03 PM Terry Reedy apparently wrote: I have not seen 3.0 emit a % deprecation warning. Point taken. But the vocabulary of PEP 4 suggests that "obsolete" and "deprecated" are synonyms, and PEP 4 lists obsolete modules without deprecation warnings. Alan Isaac -- http://mail.pytho

Re: string formatting documentation

2009-01-19 Thread Alan G Isaac
On 1/19/2009 3:03 PM John Machin apparently wrote: It is not deprecated YET; see this: http://docs.python.org/3.0/whatsnew/3.0.html#changes-already-present-in-python-2-6 PEP 3101: Advanced String Formatting. Note: the 2.6 description mentions the format() method for both 8-bit and Unicode strin

Re: string formatting documentation

2009-01-19 Thread Terry Reedy
Alan G Isaac wrote: On Mon, 19 Jan 2009 14:44:01 +, Alan G Isaac wrote: we are supposed to prefer No, no 'supposed to's. You are not even 'supposed to' like or use Python. (Unless, I supposed, an employer demands it. But that is another story.) Certainly, one is not 'supposed to' pre

Re: string formatting documentation

2009-01-19 Thread Steven D'Aprano
On Mon, 19 Jan 2009 15:38:02 +, Alan G Isaac wrote: > But of more interest: you claim PEP 4 is not relevant, and that old > string formatting is NOT deprecated. I would like assurance that it is > not deprecated. Can you back that? If you want to know what python-dev have in mind, you have to

Re: string formatting documentation

2009-01-19 Thread John Machin
On Jan 20, 2:38 am, Alan G Isaac wrote: > But of more interest: you claim PEP 4 is not relevant, > and that old string formatting is NOT deprecated. > I would like assurance that it is not deprecated. It is not deprecated YET; see this: http://docs.python.org/3.0/whatsnew/3.0.html#changes-alread

Re: string formatting documentation

2009-01-19 Thread Alan G Isaac
On Mon, 19 Jan 2009 14:44:01 +, Alan G Isaac wrote: we are supposed to prefer '{0:>10}'.format('wtf?') to '%10s' % 'wtf?' and '{{0}}{0}'.format('wtf?').format('wtf?') to '%%s%s' % 'wtf?' % 'wtf?' On 1/19/2009 10:01 AM Steven D'Aprano apparently wrote: Well, that second example certainly

Re: string formatting documentation

2009-01-19 Thread Steven D'Aprano
On Mon, 19 Jan 2009 14:44:01 +, Alan G Isaac wrote: > On 1/17/2009 3:59 PM Ned Deily apparently wrote: >> > > > Ah, so the rumors are true: > we are supposed to prefer > '{0:>10}'.format('wtf?') > to > '%10s

Re: string formatting documentation

2009-01-19 Thread Alan G Isaac
On 1/17/2009 3:59 PM Ned Deily apparently wrote: Ah, so the rumors are true: we are supposed to prefer '{0:>10}'.format('wtf?') to '%10s' % 'wtf?' and '{{0}}{0}'.format('wtf?').format('wtf?') to '%%s%s' % 'wtf?