开发者

Is there macros for rewrite CPS?

开发者 https://www.devze.com 2023-01-29 01:47 出处:网络
For example I have two async methods (get-a 10 (lambda (a) (get-b a (lambda (b) (display b))) but I want to write something similar to

For example I have two async methods

(get-a 10 (lambda (a) (get-b a (lambda (b) (display b)))

but I want to write something similar to

(define (a (get-开发者_StackOverflow中文版a 10)))
(define (b (get-b a)))
(display b)


No. CPS is a global transformation, and macros local transformers. See also "On the Expressive Power of Programming Languages".

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号