add tail call behavior test for -> contract
svn: r4779 original commit: 18288da49361fcf70780ae1330c39f4992516e10
This commit is contained in:
parent
3ad9a94b46
commit
f71da72753
|
@ -4244,6 +4244,28 @@
|
|||
(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))))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;;
|
||||
;; provide/contract tests
|
||||
|
|
Loading…
Reference in New Issue
Block a user