[Zope3-dev] RE: [Zope3-checkins] CVS: Zope3/lib/python/Zope/TextIndex - TextIndexInterfaces.py:1.3 TextIndexWrapper.py:1.3

Gary Poster gary@modernsongs.com
Wed, 4 Dec 2002 14:37:19 -0500


Hm.  That's a reasonable and practical stylistic convention, but one
I've been on the fence about in my own thoughts.  At first blush it
seems it would be a hard line to draw sometimes.

In any case, (on a quick search) I don't see this in the Python or Zope
style guides.  Is it worth mentioning one of those places, or does it
fall somewhere closer to "common sense" than "style"?

Gary



-----Original Message-----
From: Guido van Rossum

> Also, you're the best person to answer this in the universe, I
imagine,
> so out of curiosity, why aren't these attributes in the interface and
> implemented as Python 2.2 properties?

Partly historic, partly because I didn't think about it, but now that
I *do* think about it, I think it's right they are methods: they can do
some non-trivial computation (calculating the size of a persistent
BTree requires faulting in the buckets).

--Guido van Rossum (home page: http://www.python.org/~guido/)