[ZPT] Re: tal:define and metal:use-macro

Evan Simpson evan@4-am.com
Thu, 19 Dec 2002 13:12:25 -0600


Scott Burchill wrote:
> Willem Broekema wrote:
> 
>> Why is 'tal:define' ignored when there's also 'metal:use-macro' ?

Because 'metal:use-macro' replaces the entire element with the macro 
expansion before any TAL is executed.  Conceptually, at least, all METAL 
  statements are performed before all TAL statements.  This isn't 
*quite* true in the current implementation, but it is certainly true for 
statements on the same tag.

ZPT should probably issue a warning when any TAL is placed on the same 
tag as 'metal:use-macro'.  All other METAL is safe, since the defining 
of macros and slots has no effect on template execution, and filling a 
slot preserves TAL.

Cheers,

Evan @ 4-am