2010/02/24

TSS let/cc, try



 (define-syntax letcc 
(syntax-rules ()
((letcc var . body)
(call-with-current-continuation
(lambda (var) . body)))))
(define-syntax try
(syntax-rules ()
((try var a . b)
(letcc success
(letcc var (success a)) . b))))



0 件のコメント:

コメントを投稿