On Mon, Jul 10, 2006 at 05:43:18PM +0200, Buchcik, Kasimier wrote:
> > I think we could easily change this further to cleanup tree fragments,
> > which were created in/underneath an instruction, directly after an
> > instruction exits - if this is what you mean. Taking xsl:for-each
> 
> [...]
> 
> While implementing the cleanup of temporary tree fragments directly
> when an instruction exits, I noticed that we'll get problems if
> trying to do the same for extension elements. With the current
> implementation of EXSLT's functions, this won't work:
> 
> <func:function name="foo:foo">
>   <func:result>result</func:result>
> </func:function>
> 
> When <func:result> exits, we still need to preserve the tree fragment,
> until <func:function> exits. With xsltRegisterTmpRVT(), there's no
> way to define the scope of the tree fragment; e.g. one cannot bind
> it to the <func:function> (e.g. with a unique stamp for a specific
> instruction/extension element). Since this cannot be undone
> (xsltRegisterTmpRVT() is probably also used in other extension
> elements),
> I'll leave out extension elements from this optimization. Maybe we can
> optimize this also for EXSLT's functions; we'll need an other
> registration
> function for this.

  Now that you raise it, I remember being really annoyed by func:function
precisely because the RVT outlived the scope of the current template, I
don't remember how I did actually :-)

Daniel

-- 
Daniel Veillard      | Red Hat http://redhat.com/
[EMAIL PROTECTED]  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
_______________________________________________
xslt mailing list, project page http://xmlsoft.org/XSLT/
[email protected]
http://mail.gnome.org/mailman/listinfo/xslt

Reply via email to