(I'm cc'ing zope-dev this time)

Evan Simpson wrote:
Jim Penny wrote:

Hate this.  Looks like a typecast of some kind, int is way to overused
for this.  If you must, why not index:  ?



Hmmm. I hadn't thought of that before, but I've certainly wanted to tell the path traverser whether to use attribute, index, or key access on several occasions (using 'items' as a dictionary key bites me regularly). This suggests the following prefixes:

'key:' -- use item access with the prefixed string.
'index:' -- use item access with the prefixed integer.
'attr:' -- use attribute access with the prefixed string.

I agree, "index:" is better. I had a mental block that made me think of only "item:", which would be ambiguous.


Shane


_______________________________________________
Zope-Dev maillist - [EMAIL PROTECTED]
http://mail.zope.org/mailman/listinfo/zope-dev
** No cross posts or HTML encoding! **
(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope )

Reply via email to