except clause syntax question

Charles Yeomans charles at declareSub.com
Tue Jan 31 19:27:38 EST 2012

On Jan 31, 2012, at 7:12 PM, Terry Reedy wrote:

> On 1/31/2012 8:57 AM, Charles Yeomans wrote:
>> In any case, though I appreciate your attempt at a post hoc justification,
> > I was hoping for a positive explanation.
> I think the best you are going to get is that Python somewhat consistently*, for both practical and historical reasons#, uses tuples when the syntax allows an object or collection of objects.
> * except, isinstance, isubclass, ''%x, perhaps other places.
> In the last case, that creates a problem when one wants to interpolate a tuple as an object rather than having it viewed as a container of several objects to be interpolated. That was on
> # Python once treated tuples as different from lists in ways that is not true now. (Read the 1.5 docs if really interested.)

I'll do that.  Thanks.

Charles Yeomans

More information about the Python-list mailing list