Re: Erratum: XPaths in Canonical XML Recommendation

BTW, I certainly don't mind seeing the more esoteric XPath questions come
up (like Jeni's or my one of some weeks back).  

Jeni, just so you know, John B. is laps ahead of the majority of us when
it comes to understanding the intricacies of XPath.  And since a solid understanding
of XPath is very beneficial to making the most of XML Signature, it is good
to see these questions posed on the list.

Regards, Ed

-- Original Message --

>Hi John,
>
>> Thanks for the note, but I don't understand why you claim that //.
>> is illegal. From the XPath spec:
>>
>> Expr -> ... -> LocationPath -> AbsoluteLocationPath ->
>> AbbreviatedAbsoluteLocationPath -> '//' RelativeLocationPath -> '//'
>> Step -> '//' AbbreviatedStep -> '//.'
>>
>> Clearly it is legal according the BNF rules in the XPath
>> specification. Perhaps you have an implementation of XPath that
>> contains an error?
>
>Cripes, you're right. I apologise. I'd never seen that construction
>used before because it's meaningless except, I guess, in this case.
>When you write it out in full you can see why:
>
>  /descendant-or-self::node()/self::node()
>
>is equivalent to:
>
>  /descendant-or-self::node()
>
>Sorry for my error,
>
>Jeni
>
>---
>Jeni Tennison
>http://www.jenitennison.com/
>
>

-----------------------------------------------------------------------------------------------
Ed Simon
<edsimon@xmlsec.com>
XMLsec Inc.

Interested in XML Security Training and Consulting services?  Visit "www.xmlsec.com".

Received on Saturday, 15 December 2001 10:11:20 UTC