When the current() function is called within a pattern appearing as part of an instruction (that is, the count or from patterns of xsl:number, or the group-starting|ending-with patterns of xsl:for-each-group), a Saxon internal error may occur while compiling the stylesheet. The message is
"*** Internal Saxon error: local variable encountered whose binding has been deleted Variable name: saxon:current987654321
The stack trace will generally contain a number of nested calls to:
A patch is being placed in Subversion.