xsl-list
[Top] [All Lists]

Re: [xsl] xsl:sequence

2006-08-08 06:37:11
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






















        

        
                
___________________________________________________________________________ 
Découvrez un nouveau moyen de poser toutes vos questions quelque soit le sujet 
! 
Yahoo! Questions/Réponses pour partager vos connaissances, vos opinions et vos 
expériences. 
http://fr.answers.yahoo.com 


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>