Re: [xsl] Where is 'intersect' Operator Defined in XPath 3?

Subject: Re: [xsl] Where is 'intersect' Operator Defined in XPath 3?
From: "C. M. Sperberg-McQueen cmsmcq@xxxxxxxxxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx>
Date: Mon, 8 Aug 2022 21:24:26 -0000
"Dimitre Novatchev dnovatchev@xxxxxxxxx"
<xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> writes:

> Thus the language is in such a state that not all operators can be
> found in a single document ...

I think that may depend on how one chooses to define 'operator'.

In general, the operators named in the Functions and Operators spec seem
to operate on values of the datatypes defined by XSD; there are some
functions that take sequences of values as arguments, but no named
operators on sequences of values.

Union, intersection, and set difference on node sequences are not
covered in the F&O spec; unless I have overlooked them, neither are "to"
(as in "1 to 100"), "and", "or", "not", "if" ... "then" ... "else",
"instance of", "treat as", "castable as", "cast as".

These are all keywords in XPath and must be (and are) defined in the
XPath spec.

Perhaps some illogicality arose in the division of labor made when the
detailed documentation of the function library was split off from the
XPath spec into a separate document.  Or perhaps there is a definition
of "operator" somewhere that explains all.

In either case, it doesn't seem quite as accidental as Mike Kay's
self-depreciating account might suggest.

Michael Sperberg-McQueen




> On Mon, Aug 8, 2022 at 10:14 AM Michael Kay mike@xxxxxxxxxxxx
<xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> wrote:
>
>  I'm afraid the distribution of text between the various specs often owes
more to the question of who stepped up to do the editorial work than to any
top-down design of the document suite.
>
>  Michael Kay
>  Saxonica
>
>  > On 8 Aug 2022, at 16:54, Norm Tovey-Walsh ndw@xxxxxxxxxx
<xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> wrote:
>  >
>  > "Eliot Kimber eliot.kimber@xxxxxxxxxxxxxx"
<xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> writes:
>  >> I was looking in the XPath 3.1 functions and operators docbso I think
>  >> my question still standsbwhy do I not find a definition of the
>  >> intersect operator in the Functions and Operators spec?
>  >
>  > I donbt know if therebs a good editorial reason, or if itbs simply
a
>  > matter of oversight. I donbt think it would have been unreasonable to
>  > expect an bop:intersectb function described in F&O with a pointer
from
>  > the bintersectb operator in XPath to that function. But thatbs not
the
>  > way the XPath spec got written. B/\_(c)_/B/
>  >
>  >> And also why does a google search not find the entry in the XPath
>  >> spec?
>  >
>  > According to a bit of spam that drifted past me today, Google/Alphabet
>  > are engaged in a broad program of mind control over the entire human
>  > race. Perhaps theybre distracted a bit from the search engine
business.
>  >
>  >                                        Be seeing you,
>  >                                          norm
>  >
>  > --
>  > Norman Tovey-Walsh <ndw@xxxxxxxxxx>
>  > https://nwalsh.com/
>  >
>  >> Because things are the way they are, things will not stay the way they
>  >> are.--Bertolt Brecht
>  >


--
C. M. Sperberg-McQueen
Black Mesa Technologies LLC
http://blackmesatech.com

Current Thread