#131 xsl:number, single, count matches nothing

v6.5.2
closed
Michael Kay
5
2012-10-08
2003-03-25
Michael Kay
No

When the instruction:

<xsl:number level="single" count="x" format="[1]/>

is used, and the count pattern does not match the
context node or any of its ancestors, the correct
output is an empty list: "[]". Saxon outputs "[0]".

The problem affects Saxon 6.5.2, 7.4, and all other
releases.

Source code fixed in both branches.

Test case: numbering90.

(Note, Xalan in this case apparently outputs "" rather
than "[]". I believe the correct output is "[]".)

Discussion