Returns the nodes in the node set passed as the first argument that precede, in document order, the first node in the node set passed as the second argument. If the second node set is empty, then the first node set is returned.
leading($nodes1 as item()*, $nodes2 as item()*) ➔ item()*
First node set, in document order
Second node set, in document order
Links to specifications
Requires Saxon-PE or Saxon-EE. Available for Java and C/C++ only (not .NET).
Notes on the Saxon implementation
Saxon does not implement the EXSLT rule "If the first node in the second node set is not contained in the first node set, then an empty node set is returned." This rule prevents a pipelined implementation. Saxon returns all nodes that precede the first node of the second node-set in document order, whether or not the two node-sets intersect.