Re: [xsl] RE: Cheaper to prepend or append an item to a sequence?

Subject: Re: [xsl] RE: Cheaper to prepend or append an item to a sequence?
From: Michael Kay <mike@xxxxxxxxxxxx>
Date: Tue, 22 Feb 2011 14:24:59 +0000
In the functional language Haskell, there is a clear disadvantage of appending an item onto the end of a list, and developers are strongly encouraged to build lists by prepending an item onto a list.

It would be interesting to know the basis for this advice.


(a) Does the Haskell language mandate an implementation?

(b) or is there only one implementation?

(c) or is there so much commonality between implementations that such advice applies to all of them?

(d) or is the book written for users of a particular implementation?

XSLT is more like SQL in this regard - different optimizers do things differently.

Michael Kay
Saxonica

Current Thread