W3C home > Mailing lists > Public > public-qt-comments@w3.org > March 2010

[Bug 9298] New: namespace-node() as a KindTest in an Axis Step

From: <bugzilla@wiggum.w3.org>
Date: Mon, 22 Mar 2010 18:40:39 +0000
To: public-qt-comments@w3.org
Message-ID: <bug-9298-523@http.www.w3.org/Bugs/Public/>
http://www.w3.org/Bugs/Public/show_bug.cgi?id=9298

           Summary: namespace-node() as a KindTest in an Axis Step
           Product: XPath / XQuery / XSLT
           Version: Working drafts
          Platform: PC
        OS/Version: Windows NT
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XPath 2.1
        AssignedTo: jonathan.robie@redhat.com
        ReportedBy: mike@saxonica.com
         QAContact: public-qt-comments@w3.org


XPath 2.1 has introduced the syntax namespace-node() as a new kind of KindTest.
As such it can be used in an AxisStep, for example we can write
A/B/namespace-node().

Section 3.2.4 says: "If the axis name is omitted from an axis step, the default
axis is child unless the axis step contains an AttributeTest or
SchemaAttributeTest; in that case, the default axis is attribute. "

Logically, this rule should be extended so that when the axis step contains the
KindTest namespace-node(), the default axis is namespace.

The only difficulty here of course is that the namespace axis is deprecated,
which means that the KindTest namespace-node() when used as an AxisStep should
be deprecated, but it seems odd to introduce new syntax and deprecate it at the
same time. Yet the alternative, of introducing an asymmetry between a KindTest
used in an AxisStep and a KindTest used as an ItemType seems worse.

The current spec says that you can write A/B/namespace-node() and it will never
select anything, which also seems highly unsatisfactory.


-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
Received on Monday, 22 March 2010 18:40:41 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 March 2012 18:14:59 GMT