[ZPT] TALES: Path expressions?
Alan Kennedy
zpt@xhaus.com
Wed, 6 Mar 2002 10:01:55 EST5EDT
> Joel wrote:
> > Possibly. But Python expressions lead to some ugliness,
such as when
> > dealing with objects with a . in their name, and having
to know whether
> > something is callable () or not.
Evan wrote:
> The language-independent concept of
> 'paths' used here is deliberately similar to Zope's own
URL-to-object
> mapping. You can address an object without having to
worry about the
> underlying details of resolving that address.
But since I am using ZPT outside of Zope, because it's
simply a great templating language, following Zope's URL-to-
object mapping is of far less concern to me.
Also, I don't see where the ugliness comes in, if I am
simply 'eval()'ing a python expression, unless python
expressions are themselves ugly. If an object is callable,
then developers could simply call it themselves.
> Joel wrote:
> > plus I think independence from Python was one of design
intentions of the
> > ZPT package.
Independence from python/jython is far less of a concern
for me.
The reasons why I'm thinking this way is that removing path
expressions from the TALES grammar and treating expressions
as path expressions makes it *much* easier to implement.
Hmmmm.
Thanks all,
Alan.
---------------------------------------------
This message was sent using WebMail by CyberGate.
http://www.gate.net/webmail