xsl-list
[Top] [All Lists]

RE: Re: XSLT 2.0: On xsl:sequence and xsl:copy-of

2003-10-10 15:06:30

Then a slight modification:

    <xsl:variable name="v1" as="item()*">
      <xsl:sequence select="/"/>
    </xsl:variable>
    <xsl:variable name="v2"  as="item()*">
      <xsl:sequence select="/"/>
    </xsl:variable>

    <xsl:copy-of select="$v1 except $v2"/>

I guess this will not produce any output -- am I right?

Correct, this will be an empty sequence.


My last question is the following:

In the example above the two sequences consist not of nodes, 
but of *references to nodes*. This is a very useful new 
datatype, not present in the XPath data model. Will it not be 
nice to explain this in detail in the XSLT spec.?


I must admit I like to think in terms of "references to nodes" rather
than "nodes" but for some reason this is not the language that the data
model uses. When it talks of a sequence "containing nodes", this is
clearly not exclusive containment, since the same node can belong to
more than one sequence. But that's the terminology that's used.

Michael Kay


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list