bug#17485: (srfi srfi-1) reduce-right does not scale, version 2.0.9

2016-07-12 Thread Andy Wingo
On Tue 21 Jun 2016 17:31, David Kastrup writes: > Andy Wingo writes: > >> I think on 2.0 that this might be an OK workaround: >> >> (define (reduce-right f ridentity lst) >>(reduce f ridentity (reverse lst))) > > So if we don't store the inverse list in-space, it needs to be either a > copy

bug#17485: (srfi srfi-1) reduce-right does not scale, version 2.0.9

2016-06-21 Thread David Kastrup
Andy Wingo writes: > Hi, > > On Tue 13 May 2014 12:47, David Kastrup writes: > >> The following code results in an error: >> >> (use-modules (srfi srfi-1)) >> (reduce-right + 0 (make-list 1 1)) >> >> Backtrace: >> In srfi/srfi-1.scm: >> 379: 19 [recur (1 1 1 1 1 1 1 1 1 ...) (1 1 1 1 1 1 1

bug#17485: (srfi srfi-1) reduce-right does not scale, version 2.0.9

2016-06-21 Thread Andy Wingo
Hi, On Tue 13 May 2014 12:47, David Kastrup writes: > The following code results in an error: > > (use-modules (srfi srfi-1)) > (reduce-right + 0 (make-list 1 1)) > > Backtrace: > In srfi/srfi-1.scm: > 379: 19 [recur (1 1 1 1 1 1 1 1 1 ...) (1 1 1 1 1 1 1 1 1 ...)] > 379: 18 [recur (1 1 1

bug#17485: (srfi srfi-1) reduce-right does not scale, version 2.0.9

2014-06-02 Thread David Kastrup
Mark H Weaver writes: > David Kastrup writes: > >> For all the cleverness involved here, one has to run through the whole >> list anyway. It makes no real sense to do this in this manner. The >> motivation may be to have a warm cache when k is small, but the result >> is self-defeating because

bug#17485: (srfi srfi-1) reduce-right does not scale, version 2.0.9

2014-06-01 Thread Mark H Weaver
David Kastrup writes: > The following code results in an error: > > (use-modules (srfi srfi-1)) > (reduce-right + 0 (make-list 1 1)) [...] > srfi/srfi-1.scm:379:31: In procedure recur: > srfi/srfi-1.scm:379:31: Throw to key `vm-error' with args `(vm-run "VM: Stack > overflow" ())'. Yes, t

bug#17485: (srfi srfi-1) reduce-right does not scale, version 2.0.9

2014-05-13 Thread David Kastrup
The following code results in an error: (use-modules (srfi srfi-1)) (reduce-right + 0 (make-list 1 1)) Backtrace: In srfi/srfi-1.scm: 379: 19 [recur (1 1 1 1 1 1 1 1 1 ...) (1 1 1 1 1 1 1 1 1 ...)] 379: 18 [recur (1 1 1 1 1 1 1 1 1 ...) (1 1 1 1 1 1 1 1 1 ...)] 379: 17 [recur (1 1 1 1 1 1