Re: [xml] lazy libxml



Daniel Veillard <veillard redhat com> writes:

On Wed, Jun 21, 2006 at 09:56:27AM +0100, Nic James Ferrier wrote:
Nothing is impossible.

I still think this would be a nice idea... I don't even think it would
be that hard to implement. What would be hard is maintaining the
separate tree with the lazy patches in until Daniel was convinced
/8->

  Well if it was one simple isolated change I would be more optimistic,
what I'm afraid of is that it would impact an awful lot of code, basically
each time a descent in the tree is needed, and that doesn't sound good:

paphio:~/XML -> grep -- '->children' *.c | wc -l
699
paphio:~/XML -> grep -- '->last' *.c | wc -l
233
paphio:~/XML ->

I think you're right. There would be hundreds, maybe more than 1000 changes.

But I'm also pretty sure that they would be pretty systematic so
applying them in the first place might not be so hard.

Then it's just a matter of using a bunch of change tracking
tools. Darcs plus some custom validation code maybe.


However, I am pursuing the idea of directly expressed lazyness managed
by the dyn:evaluate function, eg:

  <xsl:variable name="x" select="'functioncall()'"/>
  <xsl:value-of select="dyn:evaluate($x)"/>

I'm pretty sure I can achieve what I want with only this.

  At that level this might be easier, but I'm afraid it would then impact the
XSLT/XPath model, that's already quite complex.

Not sure what you mean by that. The above code is possble now with
libxslt.

The difficulty for me is if I want to find out dynamically whether a
particular value is delayed or not.

-- 
Nic Ferrier
http://www.tapsellferrier.co.uk   for all your tapsell ferrier needs



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]