|
ToDo:
|
andは真なら最後のS式の値を返すので
(define *cont* #f)
(and 10
(call/cc (lambda(k)(set! *cont* k) 20)))
した時
gosh> (define *cont* #f)
gosh> (and 10
(call/cc (lambda(k)(set! *cont* k) 20)))
*cont*
gosh> 20
gosh> (*cont*)
gosh> (*cont* 1)
1
orは真なら最初のS式の値を返すのでcall/ccまでとびません
(define *cont* #f)
(or 10
(call/cc (lambda(k)(set! *cont* k) 20)))
ので
gosh> (define *cont* #f)
gosh> (or 10
(call/cc (lambda(k)(set! *cont* k) 20)))
*cont*
gosh> 10
gosh> *cont*
#f