[Bug 27075] New: [xslt3.0ts] Streamability of void path expressions

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

            Bug ID: 27075
           Summary: [xslt3.0ts] Streamability of void path expressions
           Product: XPath / XQuery / XSLT
           Version: Working drafts
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XSLT 3.0 Test Suite
          Assignee: abel.online@xs4all.nl
          Reporter: mike@saxonica.com
        QA Contact: public-qt-comments@w3.org

A number of the new Posture+Sweep tests use void path expressions, for example
A030 uses

<xpath>descendant::document-node()/attribute()</xpath>

Rule 3 for streamability of axis steps (19.8.7.7) says:

If the statically-inferred context item type is such that the axis will always
be empty (for example, applying the child axis to a text node or the parent
axis to a document node), or if the NodeTest is one that can never select nodes
on the chosen axis (for example, selecting attribute nodes on the child axis),
then the sweep is motionless and the posture is grounded (because the
expression is statically known to return an empty sequence);

In this example both axis steps fall under this rule, so they are both
Grounded+Motionless, and therefore (under the rules for path expressions in
19.8.7.6) the path expression as a whole is Grounded+Motionless. The expected
result of the test case is given as Climbing+Consuming. 

There are other tests where only one of the axis steps is void under this rule,
for example

<xpath>descendant-or-self::foo/namespace::attribute()</xpath>

In this case I believe the spec gives the result as Grounded+Consuming, which
is reasonable enough. Saxon is smarter, and computes the result as
Grounded+Motionless, because it has already worked out that the entire path
expression is void. The expected result in the test case, however, is
Climbing+Consuming.

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

Received on Thursday, 16 October 2014 11:43:46 UTC