From f71da72753e97d8c02b733a33b2bc72e4007a03f Mon Sep 17 00:00:00 2001 From: Robby Findler Date: Sun, 5 Nov 2006 02:06:19 +0000 Subject: [PATCH] add tail call behavior test for -> contract svn: r4779 original commit: 18288da49361fcf70780ae1330c39f4992516e10 --- collects/tests/mzscheme/contract-test.ss | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/collects/tests/mzscheme/contract-test.ss b/collects/tests/mzscheme/contract-test.ss index 6bbe963..b29f4b8 100644 --- a/collects/tests/mzscheme/contract-test.ss +++ b/collects/tests/mzscheme/contract-test.ss @@ -4242,7 +4242,29 @@ (or/c (-> (>=/c 5) (>=/c 5)) boolean?)) (test-name '(or/c (-> (>=/c 5) (>=/c 5)) boolean?) (or/c boolean? (-> (>=/c 5) (>=/c 5)))) + + (test 1 + length + (let ([f (contract (-> integer? any) + (lambda (x) + (with-continuation-mark 'x 'x + (continuation-mark-set->list (current-continuation-marks) 'x))) + 'pos + 'neg)]) + (with-continuation-mark 'x 'x + (f 1)))) + + (test 2 + length + (let ([f (contract (-> integer? list?) + (lambda (x) + (with-continuation-mark 'x 'x + (continuation-mark-set->list (current-continuation-marks) 'x))) + 'pos + 'neg)]) + (with-continuation-mark 'x 'x + (f 1)))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;