summaryrefslogtreecommitdiff
path: root/test-suite/tests/peval.test
diff options
context:
space:
mode:
authorAndy Wingo <wingo@pobox.com>2012-04-26 23:40:57 +0200
committerAndy Wingo <wingo@pobox.com>2012-04-26 23:40:57 +0200
commit9d8a10a94c022e5fe4b58aa4b586eda514b1189f (patch)
treec457baf30282c232487a22155c42b025791885b8 /test-suite/tests/peval.test
parent0ea5ba9ab9e749ccb19ec12129045d0753844338 (diff)
parent4bd53c1ba39ba1c2d51ff895104f27cf4bb69e4e (diff)
downloadguile-9d8a10a94c022e5fe4b58aa4b586eda514b1189f.tar.gz
Merge remote-tracking branch 'origin/stable-2.0'
Conflicts: test-suite/tests/cse.test
Diffstat (limited to 'test-suite/tests/peval.test')
-rw-r--r--test-suite/tests/peval.test16
1 files changed, 15 insertions, 1 deletions
diff --git a/test-suite/tests/peval.test b/test-suite/tests/peval.test
index b10bedf1f..2bd8919f5 100644
--- a/test-suite/tests/peval.test
+++ b/test-suite/tests/peval.test
@@ -998,4 +998,18 @@
(pass-if-peval
(car '(1 2))
- (const 1)))
+ (const 1))
+
+ ;; If we bail out when inlining an identifier because it's too big,
+ ;; but the identifier simply aliases some other identifier, then avoid
+ ;; residualizing a reference to the leaf identifier. The bailout is
+ ;; driven by the recursive-effort-limit, which is currently 100. We
+ ;; make sure to trip it with this recursive sum thing.
+ (pass-if-peval resolve-primitives
+ (let ((x (let sum ((n 0) (out 0))
+ (if (< n 10000)
+ (sum (1+ n) (+ out n))
+ out))))
+ ((lambda (y) (list y)) x))
+ (let (x) (_) (_)
+ (apply (primitive list) (lexical x _)))))