Subject: Re: Determining the position of a specific node in the context
From: David Carlisle <davidc@xxxxxxxxx>
Date: Fri, 20 Oct 2006 00:29:26 +0100
|
test="B/following-sibling::C"
does what you want, in 1 or 2.
in 2
node()[self::B]/position() < node()[self::C]/position()
is legal but
node()[self::B]
equivalent to
B
so
node()[self::B]/position()
is B/position()
which selects a sequence of B nodes then for each returns the
position,so in general it returns a sequence (1,2,3,...count(B))
for your input it just returns
1
node()[self::C]/position()
is also 1
so
node()[self::B]/position() < node()[self::C]/position()
is
1 lt 1
which os false()
David
|