Allow variable before sort?

Hi everyone,

Would there be any problems in allowing <xsl:variable> to land before
<xsl:sort> in XSLT 4.0? No doubt engines have been able to optimize for
instances where patterns in xsl:sort/@select are replicated in the body of
an <xsl:for-each> or <xsl:for-each-group>. But is there a drawback to
letting the user declare <xsl:variable> before the sort is conducted? Many
times I have wanted to do so, to avoid repeating an in the body of the
operation.

In such cases I often resort to building a function, but some of these are
one-time deals, and it would be cleaner, from my perspective to do this
through a variable.

jk
-- 
Joel Kalvesmaki
kalvesmaki.com

Received on Tuesday, 1 December 2020 14:32:09 UTC