[Zope-dev] Re: TALES idea: tuple unpacking

Philipp von Weitershausen philipp@weitershausen.de
Wed, 23 Jul 2003 11:54:40 -0500


Jean Jordaan wrote:
>>> int:    -- Look up an item by index
>>
>> Hate this.  Looks like a typecast of some kind, int is way to overused
> 
> Aesthetically, I also find it ugly. The attractiveness of a *path* 
> expression lies in its resemblance to a *path*.

True, but we've obviously reached a point where a simple POSIX like path 
is not sufficient anymore, because we apply it to a complicated Zope 
structure. some_function/returned-dict/some_key is really comparing 
"apples to a whole fruit salad" (quote from ChrisW or SteveA, can't 
remember). Thus we need to attach some kind of extra meaning to the 
elements, not only to tell Zope where they come from and how they have 
been interpreted, but also to make it cleaner for the programmer.

> But I realise it's like the weird ++elements in Zope3 paths that
> I hope never to need to deal with but will have to swallow sometime
> willy nilly, and that no-one could think of anything better in that
> case :|

Tough luck :). Well, it's actually the same thing as above. In Zope2, 
we've mixed content, configuration, code and presentation in one 
namespace. Since Zope3 inforces their separation, it only makes sense to 
have them live in different namespaces as well (we have ++etc++, 
++skin++, ++vh++ and some more).

The decision what token to use for identifying namespaces has long been 
made. Sorry if you don't like it now... :(

Cheers,

Phil