W3C home > Mailing lists > Public > xmlschema-dev@w3.org > April 2002

Re: Selector Clarification

From: Jeni Tennison <jeni@jenitennison.com>
Date: Wed, 10 Apr 2002 09:55:10 +0100
Message-ID: <132696096904.20020410095510@jenitennison.com>
To: Daniel Veillard <daniel@veillard.com>
CC: Rahul Srivastava <Rahul.Srivastava@Sun.COM>, xmlschema-dev@w3.org
Hi Daniel,

> The XPath expresssion in the SchForSch is actually very broken, like
> in accepting "a:1", it seems it wasn't defined and tested with the
> idea that the expression would really be the normative definition.
> http://lists.w3.org/Archives/Public/www-xml-schema-comments/2002AprJun/0005.html
> I would give more trust to the written section over the expression
> itself.

Sure, but the written section at
http://www.w3.org/TR/xmlschema-1/#scc-selector-value-ok gives a more
detailed description, including some BNF which I'd take as normative,
and that allows a selector XPath of '.':

  [1]    Selector    ::=    Path ( '|' Path )*
  [2]    Path        ::=    ('.//')? Step ( '/' Step )*
  [3]    Step        ::=    '.' | NameTest
  [4]    NameTest    ::=    QName | '*' | NCName ':' '*'

I suspect that allowing '.' is actually an oversight, since compliance
with this BNF has an alternative which I think is meant to be
equivalent: "[The selector value] must be an XPath expression
involving the child axis whose abbreviated form is as given [in the
BNF] above." Mind you, they wouldn't be equivalent anyway, since the
BNF allows the descendant-or-self:: axis to be used (in the
abbreviation //), though only at the start of the path.



Jeni Tennison
Received on Wednesday, 10 April 2002 04:55:17 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:55:56 UTC