[Python-3000] [Python-Dev] dict.items as attributes [Was: The bytes type]

Tim Delaney tcdelaney at optusnet.com.au
Tue Jan 16 21:45:09 CET 2007


Guido van Rossum wrote:

> I find it hard to explain, but my gut feeling is that using an
> attribute instead of a method would be a mistake here. In the past
> I've paid deerly for ignoring my gut feelings (about language design
> as well as about other things) so I'd rather wait until a rational
> explanation comes to me instead of changing my mind now. I'll gives a
> few half-reasons that might help:

My gut tells me the same thing. I was trying to work out why, and the 
"independent state" bit seemed to be it - except then I worked out that 
there wouldn't be any.

But the idea of a property returning an object as complex as a view still 
feels wrong to me.

Tim Delaney 



More information about the Python-3000 mailing list