[plt-scheme] r6rs vs module language performance

From: Dave Gurnell (d.j.gurnell at gmail.com)
Date: Fri Jun 27 12:14:34 EDT 2008

> The `scheme/base' version uses `(foldl append ...)', and the R6RS
> version uses `(fold-left append ...)'. Those look the same, but it
> turns out that `foldl' and `fold-left' pass arguments to the given
> procedure in opposite orders. For the R6RS version, you want `(lambda
> (x y) (append y x))' instead of just `append'.

Now, if that isn't going to be an enormous source of bugs, I don't  
know what is.

Am I right in saying that foldl is consistent with SRFI/1 fold and  
R6RS is the one breaking the mould. That seems a tad bizarre.

-- Dave

Posted on the users mailing list.