[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Case of function names (Was: Re: comments on Decem

Subject: RE: Case of function names (Was: Re: comments on December F&O draft)
From: "Michael Kay" <michael.h.kay@xxxxxxxxxxxx>
Date: Mon, 7 Jan 2002 13:28:58 -0000
RE: Case of function names (Was: Re:  comments on Decem
> I believe these should change in any case. (Apart from anything else I
> don't see any need for constructors at the user level as I
> commented in my original F&O commnets list)
I'm not keen on constructors as currently defined either, but we do need
something that says which of the following is a static error and which is a
dynamic error:

(a) date("2002-01-05$$")

(b) date(concat("2002", "-", "01", "-", "05$$"))

(c) let $x := "2002"
    date(concat($x, "-", "01", "-", "05$$"))

The main reason for introducing constructors was to provide an equivalent to
literals, for those data types that have no native literal syntax in the
language. I personally like the idea of using identical syntax for
constructors and for conversion functions, so long as we can get the
error-handling right.

I'd also like to allow an XPath processor to reject any of the above
statically, which might mean we have to introduce some
implementation-dependence: "if the values of the arguments to a function
call are known statically (whether or not they are expressed as literals),
then an XPath processor *may* evaluate the result of the function
statically, and *may* report any error that results from evaluating the
function as a static error". In the case of functions classified as
constructors, with literal arguments, that *may* is currently a *must".

Mike Kay

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.