[Bug 27078] New: [xslt3.0ts] xp-striding-grounded-motionlessA007 (namespace nodes)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 27078] New: [xslt3.0ts] xp-striding-grounded-motionlessA007 (namespace nodes)

Bugzilla from bugzilla@jessica.w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=27078

            Bug ID: 27078
           Summary: [xslt3.0ts] xp-striding-grounded-motionlessA007
                    (namespace nodes)
           Product: XPath / XQuery / XSLT
           Version: Working drafts
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XSLT 3.0 Test Suite
          Assignee: [hidden email]
          Reporter: [hidden email]
        QA Contact: [hidden email]

This test contains a number of paths starting with namespace-node(), that
expect to be grounded and motionless.

Some of them have incorrect results according to the spec, e.g.

namespace-node()/self::node() should be climbing and motionless.

Some of them have results where it perhaps the spec could do better, e.g.

namespace-node()/descendant-or-self::node() is roaming and free-ranging
according to the spec, but with more careful analysis could be made climbing
and motionless. (But is it worth it?)

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

Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 27078] [xslt3.0ts] xp-striding-grounded-motionlessA007 (namespace nodes)

Bugzilla from bugzilla@jessica.w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=27078

Abel Braaksma <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[hidden email]

--- Comment #1 from Abel Braaksma <[hidden email]> ---
> namespace-node()/self::node() should be climbing and motionless.

No I don't think so, because the rh-side returns the empty sequence (or do I
misunderstand the principal node kind rule here?) and the rule says that in
that case the result is grounded and motionless:

19.8.7.7
3. If the statically-inferred context item type is such that the axis will
always be empty [...] then the sweep is motionless and the posture is grounded

> namespace-node()/descendant-or-self::node() is roaming and free-ranging

Similar to above, unless, indeed, I have misunderstood the principal node kind
rule.

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

Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 27078] [xslt3.0ts] xp-striding-grounded-motionlessA007 (namespace nodes)

Bugzilla from bugzilla@jessica.w3.org
In reply to this post by Bugzilla from bugzilla@jessica.w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=27078

--- Comment #2 from Michael Kay <[hidden email]> ---
The principal node kind rule only affects axis steps that use a NameTest, not
those that use a KindTest. node() is a KindTest. So self::node selects the node
whatever kind it is, whereas self::* selects it only if it is of the principal
node kind.

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

Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 27078] [xslt3.0ts] xp-striding-grounded-motionlessA007 (namespace nodes)

Bugzilla from bugzilla@jessica.w3.org
In reply to this post by Bugzilla from bugzilla@jessica.w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=27078

--- Comment #3 from Abel Braaksma <[hidden email]> ---
Just checked how we did it, we indeed return a namespace on
namespace-node()/self::node(). So, indeed, I misinterpreted the rules on
principal node kind for these tests. I will update them.

I agree that I don't think it is worthwhile to optimized
attribute()/descendant-or-self::node(), we already optimize
attribute()/descendant::node() (empty sequence) and that seems to be good
enough for me.

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

Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 27078] [xslt3.0ts] xp-striding-grounded-motionlessA007 (namespace nodes)

Bugzilla from bugzilla@jessica.w3.org
In reply to this post by Bugzilla from bugzilla@jessica.w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=27078

--- Comment #4 from Abel Braaksma <[hidden email]> ---
> namespace-node()/self::node() should be climbing and motionless.

This is a result of the current XP30 REC: the expression should throw an error.
Quote:

<quote>
If the axis name is omitted from an axis step, the default axis is child, with
two exceptions: if the NodeTest in an axis step contains an AttributeTest or
SchemaAttributeTest then the default axis is attribute; if the NodeTest in an
axis step is a NamespaceNodeTest then a static error is raised [err:XQST0134] .
</quote>

This was actually part of a bug I raised and most recently, a response from
Jonathan told me that the WG is still figuring out how to fix it with an
erratum.

The reason it has motionless + grounded is because if a step raises an error,
it should be considered as motionless and grounded: errors are not part of the
analysis.

> namespace-node()/descendant-or-self::node()

Same is true for this one, the first step is an error, result type of errors is
the empty sequence, and the analysis should therefore consider the lh-side as
an empty sequence, and the rh-side then doesn't matter anymore.

I have marked (but later forgot) this specific case in the
_base-expressions.xml (in the tests/sandp dir) which forms the basis of the
test generator, as follows:

<!-- if the static result type is an error, it is the empty sequence in
posture/sweep analysis
     note: in XP31 the default axis for such test is the namespace axis,
bug#26788 -->
<production node-type="error">namespace-node()</production>

I'm not sure what the best cause of action is here.

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

Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[Bug 27078] [xslt3.0ts] xp-striding-grounded-motionlessA007 (namespace nodes)

Bugzilla from bugzilla@jessica.w3.org
In reply to this post by Bugzilla from bugzilla@jessica.w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=27078

Abel Braaksma <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|---                         |FIXED

--- Comment #5 from Abel Braaksma <[hidden email]> ---
The WG accepted the resolution as mentioned in the Description of the bug entry
and accepts that this will be the status quo even though an erratum is not yet
published for XP30. See minutes of 2014-10-23 (member only).

Fixed in rev#764 in XT3 repository.

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

Loading...