[Zope-dev] Minor quibble with the "let" tag

Phillip J. Eby pje@telecommunity.com
Wed, 11 Aug 1999 23:17:11 -0500


At 11:01 PM 8/11/99 +0200, Alexander Staubo wrote:
>For programmers (like me) who like our syntax consistent, the inability
>to write
>
>  <dtml-let foo = 1>
>
>(because spaces are not permitted around the equivalence operator) is
>annoying. I have to write
>
>  <dtml-let foo=1>
>
>and that's just plain "ugh!" in my book.

You can always say:

<dtml-let foo="  1  "  >


>Can't something be done about this? Why not accept whitespace in the
>first place? Should be simple enough, shouldn't it (looking at
>DT_Let.py, I don't see exactly why not)?

Hmmm.  Well, if you see a reasonable way to parse it that doesn't break
anything else, why not submit a patch?  The main reason it's the way it is,
is that I based the code on parsing of other DTML tags' parameters, and
thus allowing whitespace would not be consistent.  I believe the other tags
don't allow whitespace because attributes can be used without values.