ikarus/src/tests/tests-5.2-req.scm

19 lines
464 B
Scheme
Raw Normal View History

2006-11-23 19:33:45 -05:00
(add-tests-with-string-output "overflow"
[(letrec ([f
(lambda (i)
(when (fx<= i 1000)
(let ([x (make-list 1000)])
(f (fxadd1 i)))))])
(f 0)
100) => "100\n"]
[(letrec ([f
(lambda (i)
(when (fx<= i 100000)
(let ([x (list 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0)])
(f (fxadd1 i)))))])
(f 0)
100) => "100\n"])