xsl-list
[Top] [All Lists]

Re: [xsl] current() within a key element's @use

2012-12-28 12:06:34
Chris Maloney wrote:
As for a work-around, the following works with xsltproc, but
interestingly, not with Saxon.  Saxon complains "key() function cannot
be used here".  (This is a variant of the XSLT that Dimitre posted on
SO):

       <xsl:key name='kTagUsage' match='tagUsage' use='@render'/>
       <xsl:key name="kRendByUsageGi" match="rendition"
         use="key('kTagUsage', @xml:id)/@gi"/>

Saxon (6.5?) is right to complain as the errata E13 (http://www.w3.org/1999/11/REC-xslt-19991116-errata/) to the XSLT 1.0 spec says "It is an error for the value of either the use attribute or the match attribute to contain a VariableReference, or a call to the key function.".


--

        Martin Honnen --- MVP Data Platform Development
        http://msmvps.com/blogs/martin_honnen/

--~------------------------------------------------------------------
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>
--~--