[xsl] Unexpected ('a', 'b')[fn:position()] result

Subject: [xsl] Unexpected ('a', 'b')[fn:position()] result
From: "Rachel D. Basse" <honestrosewater@xxxxxxxxx>
Date: Tue, 6 Mar 2007 18:56:03 -0500
I am using XSLT 2.0, XPath 2.0, and Saxon-B 8.9 (which I dearly love). 

This one has driven me completely batty. By all tests and appearances, 

<xsl:template match="/">
 <xsl:sequence select="fn:position()"/>

returns the integer 1,

<xsl:template match="/">
 <xsl:sequence select="('a', 'b')[1]"/>

returns the string 'a', and

<xsl:template match="/">
 <xsl:sequence select="('a', 'b')[fn:position()]"/>

returns ('a', 'b'). 

Why is this? Everything tells me the last expression should evaluate to 'a'. Did I miss something?

Thanks for reading,
Rachel Basse

Care2 make the world greener!

Stop the Forest Service from killing more wolves, bears, cougars, and other animals in the wild:

http://www.Care2.com  Free e-mail. 100MB storage.  Helps nonprofits. 

Current Thread