[Bug 24496] Streamability of xsl:try can be improved with a choice operand group for xsl:catch

https://www.w3.org/Bugs/Public/show_bug.cgi?id=24496

--- Comment #3 from Abel Braaksma <abel.braaksma@xs4all.nl> ---
I think it is worthwhile to go over the motivation behind this change, as on
last telcon, several members, including me, found disallowing streaming in such
scenarios too pedantic towards users.

A non-conclusive list of arguments in favor of this change, in no particular
order:

1. Orthogonality with xsl:choose, which has an almost similar structure, and
uses the choice operand group.

2. While using try/catch for branching is not considered a good programming
practice, it is in common use in programming languages that support try/catch,
henceforth, we should not force people to change their programming habits when
they require streaming for try/catch.

3. In cases where the try-part introduces new streaming, or a grounded
expression, the catch-part cannot currently consume the streamed node. This is
a potential use-case that is not easily possible without this rule:

<xsl:try>
    <xsl:stream href="@source">
       <xsl:apply-templates />
    </xsl:stream>
    <xsl:catch>
       <error for-file="{@source}">
           <xsl:copy-of select="." />
       </error>
    </xsl:catch>
</xsl:try>

4. The change is minimal and does not introduce new features, it merely
finetunes the rules and makes them more consistent.

5. Anything else I forgot? ;)

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Thursday, 6 March 2014 16:56:21 UTC