Subject: Re: [xsl] Re: OOXML From: Liam Quin <liam@xxxxxx> Date: Tue, 1 Jul 2008 12:35:35 -0400 |
On Mon, Jun 30, 2008 at 10:31:37PM +1000, Deborah Pickett wrote: > Case in point: I don't consider XSLT to be functional because of the > hoops you have to go through to get something resembling lambda > functions. On the other hand, it's a great model of a declarative > language, at least my definition of one. Yes -- strictly speaking XSLT and XQuery are declarative and not functional -- functions are not first-class objects and the languages are not based on the lambda calculus & combinator theory. People use the term "functional" loosely to mean "declarative", and XSLT and XQuery do have referential transparency: in a given scope, a "variable" is always bound to the same value, and although aliasing is permitted, the aliases are not mutable. This is why you can't write a random number function rand() in Xquery (say) that returns a different number each time you call it. > Closures are something I'd be curious to see done in XSLT, though I > still have never come across a programming problem in real life that was > best solved by using them. It's not impossible that we'll see higher-order functions in a future version of XSLT. They're particularly useful for things like sorting and grouping, for example. Liam -- Liam Quin, W3C XML Activity Lead, http://www.w3.org/People/Quin/ http://www.holoweb.net/~liam/ * http://www.fromoldbooks.org/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Re: OOXML, Dimitre Novatchev | Thread | RE: [xsl] Re: OOXML, Michael Kay |
Re: [xsl] applying templates to att, David Carlisle | Date | RE: [xsl] applying templates to att, Michael Kay |
Month |