Altova Mailing List Archives


Re: [xsl] xsl:sequence

From: Florent Georges <darkman_spam@-------->
To:
Date: 8/8/2006 1:37:00 PM
Florent Georges wrote:

> David Carlisle wrote:

> > No, it's a single text node generated by the value-of,
> > that text node then gets used to generate the content of
> > the element (and further merging, or separators might
> > happen at that point) but first the text node is generated
> > using 5.7.2.

>   Mmh, we are still speaking about:

>     <foo>one<!-- hmm -->two</foo>
>     <xsl:value-of select="foo"/>

> right?  So the element is not created, it is used.  More
> precisely its string value is used.  And its string value is
> the concatenation of all its descendant text nodes, so
> "onetwo".

>   But I'm feeling we don't speak about the same thing?

  Mmh, I think I didn't understand totaly right your response before
posting.  It seems we are speaking about the same thing.

  Of course, there are cases in atomization then cast to string where
the string value is not used, and really a cast from an atomic type to
a string is used.

  But the mechanism is the same (we go through the typed value instead
of the string value): the sequence contains no text node, but element
nodes, it is atomized, then "Every value in the atomized sequence is
cast to a string" [XSLT2 '5.7.2/4].  *Then* occurs the concatenation
with a separator.

  Adjacent text nodes are merged in the input sequence of the value-of
(in this case there is no text node).  The produced text node may be
merged with adjacent text nodes when it is attached to a tree (so after
being created).  But the result of the instruction above is not related
to text nodes merging.

  Did I miss something?

  Regards,

--drkm






















	

	
		
___________________________________________________________________________ 
Dicouvrez un nouveau moyen de poser toutes vos questions quelque soit le sujet ! 
Yahoo! Questions/Riponses pour partager vos connaissances, vos opinions et vos expiriences. 
http://fr.answers.yahoo.com

Disclaimer

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.