No variables allowed in @use in xsl:key. Note: This change invalidates the function-xslt2.xsl template, so further tweaks will be needed to overall XSLT 2.0 processor logic.