Tuple Format?

Grant Edwards nobody at nowhere.nohow
Sat Sep 2 22:49:58 EDT 2000


In article <39B1349A.64C92E0D at alcyone.com>, Erik Max Francis wrote:
>Grant Edwards wrote:
>
>> One thought would be to use the single quotes for tuple delimiters (as in
>> `a,b,c' or `x' or `'). This has the advantage (in my mind) of reminding one
>> that tuples are like strings: immutable.
>
>Then how would you ever distinguish between the _string_ 'a,b,c' and the
>_tuple_ ('a','b','c')?

Single quotes would not be string delimiters any more.  Strings would all be
double-quoted. That means we'd loose the convenience of being able to type
things like 'he said "this is a string."' and would have to fall back to
escaping quotes inside strings: "he said \"this is a string\".".

This would, of course, break tons and tons of existing code with little
benefit other than eliminating the "weird" bit about singleton and empty
tuples and eliminating some ambiguity over whether commas are part of
certain statement's syntax or are tuple-constructors.

I don't think the single back-quote "`" is used for anything in Python, is
it?

-- 
Grant Edwards                   grante             Yow!  .. I must be a
                                  at               VETERINARIAN...
                               visi.com            



More information about the Python-list mailing list