On 15/04/2011 16:38, Philipp Kursawe wrote:
Hello Michael,
ancestor-or-self::*[@data][1]/@data
Or if you prefer, (ancestor-or-self::*/@data)[last()]
Which one is faster, if any?
Depends on your processor. You'll have to measure it and see. My guess
for Saxon is the version using [last()], but I might be wrong. The
difference is unlikely to be noticeable unless your tree is very deep.
Michael Kay
Saxonica
--~------------------------------------------------------------------
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>
--~--