[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: current() in xsl:key

Subject: Re: current() in xsl:key
From: "Michael Kay mike@xxxxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx>
Date: Thu, 29 Oct 2015 21:31:45 -0000
Re:  current() in xsl:key
No, I donbt think thatbs right. XSLT 1.0 allows the use of current()
within any XPath expression, and says that it returns the same value as the
context item for the outermost containing expression. So itbs perfectly OK
to use it within xsl:key/@use.

The main change between 1.0 and 2.0 was that 1.0 banned the use of current()
in a pattern, whereas XSLT 2.0 allows it, and defines it to return the node
being matched against the pattern. This affects the match attribute of
xsl:key, but not the use attribute.

Michael Kay

> On 29 Oct 2015, at 20:12, Ihe Onwuka ihe.onwuka@xxxxxxxxx
<xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> wrote:
> Would I be right in concluding that XSLT 1.0 restricts the availability of
current() to where apply-templates or for-each have been invoked, which would
mean it can't be invoked in the use attribute of xsl:key.
> Would it further be accurate to say this restriction is lifted in XSLT 2.0.
> ihe
> XSL-List info and archive <http://www.mulberrytech.com/xsl/xsl-list>
> EasyUnsubscribe <-list/293509> (by email <>)

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.