Re: New Python 3.0 string formatting - really necessary?
- From: Steven D'Aprano <steve@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: 21 Dec 2008 01:38:35 GMT
On Sat, 20 Dec 2008 16:20:38 -0800, r wrote:
On Dec 20, 6:05 pm, Roy Smith <r...@xxxxxxxxx> wrote:
I had an interesting experience with this recently. I was giving a
co-worker quick python into. He's an experienced programer in various
languages, but this was his first exposure to python.
He got really hung up on the % syntax. By (bad) luck, he was trying to
print a tuple (let's call it "t"), did
format % t
and was surprised at the result. It set him off on a "but that's
stupid, blah, blah, blah" rant. I haven't absorbed the new syntax well
enough to figure out if people will get hung up by this with the new
syntax.
It is stupid, more reason to fix the current problem instead creating a
whole new one.
Instead of just whinging, how about making a suggestion to fix it? Go on,
sit down for an hour or ten and try to work out how a BINARY OPERATOR
like % (that means it can only take TWO arguments) can deal with an
arbitrary number of arguments, *without* having any special cases.
Go on. Take your time. I'll be waiting.
One more big complaint "THE BACKSLASH PLAGUE". ever tried regexp?, or
file paths?. All because that little backslash char is a line
continuation character, maybe we should fix that.
This makes no sense whatsoever. How does the line continuation character
make any difference to backslashes inside a regex or a file path?
Again, instead of whinging, what's your suggestion to fix it? Another
suggestion, because your first:
Would your life end if '\' was not a continuation char?
is just stupid. The line continuation character is *irrelevant* to the
problem of backslashes inside strings. For all the use it is, you might
as well suggest changing the name None to Null.
--
Steven
.
- Follow-Ups:
- Re: New Python 3.0 string formatting - really necessary?
- From: Arnaud Delobelle
- Re: New Python 3.0 string formatting - really necessary?
- From: Aaron Brady
- Re: New Python 3.0 string formatting - really necessary?
- From: r
- Re: New Python 3.0 string formatting - really necessary?
- References:
- New Python 3.0 string formatting - really necessary?
- From: walterbyrd
- Re: New Python 3.0 string formatting - really necessary?
- From: Giampaolo Rodola'
- Re: New Python 3.0 string formatting - really necessary?
- From: r
- Re: New Python 3.0 string formatting - really necessary?
- From: Michael Torrie
- Re: New Python 3.0 string formatting - really necessary?
- From: walterbyrd
- Re: New Python 3.0 string formatting - really necessary?
- From: Roy Smith
- Re: New Python 3.0 string formatting - really necessary?
- From: r
- New Python 3.0 string formatting - really necessary?
- Prev by Date: Re: PIL on 3.x?
- Next by Date: Re: New Python 3.0 string formatting - really necessary?
- Previous by thread: Re: New Python 3.0 string formatting - really necessary?
- Next by thread: Re: New Python 3.0 string formatting - really necessary?
- Index(es):
Relevant Pages
|