W3C home > Mailing lists > Public > www-xml-linking-comments@w3.org > January to March 2002

Re: XPointer point() test

From: Michael Dyck <MichaelDyck@shaw.ca>
Date: Tue, 05 Feb 2002 23:29:08 -0800
To: Claudio Tasso <tassoc@libero.it>
Cc: www-xml-linking-comments@w3.org
Message-id: <3C60DB44.B92E1E63@shaw.ca>
Claudio Tasso wrote:
> 
> Given the following document:
> 
> <doc>Hello World</doc>
> 
> Does the expression xpointer(/doc/point()[2]) return something ?
> Is the result  a character-point between the letter "H" and the letter "e" or
> an empty location-set ?

I believe /doc/point() (and thus /doc/point()[2]) yields an empty
location-set regardless of the document. The second step is an
abbreviation of child::point(), the 'child' axis can contain only nodes,
and the 'point()' test is false for all of them, so the result is an
empty set.

So xpointer(/doc/point()[2]) always has a sub-resource error.

-Michael Dyck
Received on Wednesday, 6 February 2002 02:34:30 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 October 2009 08:39:43 GMT