Project

Profile

Help

Bug #1860

closed

Temporary output state

Added by Michael Kay over 10 years ago. Updated over 10 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
XSLT conformance
Sprint/Milestone:
-
Start date:
2013-08-09
Due date:
% Done:

0%

Estimated time:
Legacy ID:
Applies to branch:
Fix Committed on Branch:
Fixed in Maintenance Release:
Platforms:

Description

The rule in the spec is:

The instructions in the initial template are evaluated in final output state. An instruction is evaluated in the same output state as its calling instruction, except that xsl:variable,xsl:param, xsl:with-param, xsl:attribute, xsl:comment, xsl:processing-instruction, xsl:namespace, xsl:value-of, xsl:function, xsl:key, xsl:sort, and xsl:message always evaluate the instructions in their contained sequence constructor in temporary output state.

and in looking at the code in this area I notice that Saxon doesn't seem to be setting temporary output state in all these circumstances.

Note also that the diagnostics when this rule is violated are poor; they talk of executing xsl:result-document while writing a temporary tree.

Note also that in many cases (not all) the error is detectable statically, and could result in a static warning.

Actions #2

Updated by Michael Kay over 10 years ago

  • Status changed from New to In Progress

I've updated the interpreter (but not bytecode) code on the 9.6 branch to catch most of the additional cases, and have added test cases for these (result-document-1101 et seq).

Currently -1101 is failing because variable inlining means the result-document instruction is not executed while evaluating xsl:variable.

Actions #3

Updated by Michael Kay over 10 years ago

  • Status changed from In Progress to Closed

I have made the decision not to fix this on the 9.5 branch; it will be fixed in 9.6. The reason for this is that although this is a non-conformance with the spec, fixing the problem will make some stylesheets fail that are currently "working", while few users will benefit from the fix.

Although the changes are not fully implemented for 9.6, there are now test cases in place and there is therefore no need to keep the bug entry open. Therefore closing as unresolved.

Please register to edit this issue

Also available in: Atom PDF