Incorrect W3C streamability analysis for filter expressions
Given the code:
<xsl:variable name="thisNode" select="copy-of(.)"/>
<xsl:if test="$thisNode[tag[@k eq 'name:en'] and tag[@k eq 'name:ko']]">
where the context item is a streamed node, Saxon reports that the filter is not streamable according to W3C rules because it makes two downward selections.
Saxon is actually implementing the rules in the W3C draft correctly, but the rules in the (current published) W3C draft are incorrect.
Saxon implements two sets of streamability rules, the W3C rules and its own rules, and the Saxon rules in this case produce the correct answer, which means that streamed execution goes ahead. (The difference is that the Saxon rules recognise that the filter is being applied to a node which is not a streamed node.) The warning concerning the W3C rules is misleading, and will be removed.