The Scheme Programming Language says

It turns out that any program that uses call/cc can be rewritten in CPS without call/cc, but a total rewrite of the program (sometimes including even system-defined primitives) might be necessary.

What are the general techniques to

  • convert a program using call/cc to a program using functions written in CPS

  • convert in the reverse direction?

  • $\begingroup$ Have you read the Wikipedia page? It has examples and shows how to perform the conversion. $\endgroup$ – Gilles Aug 10 at 20:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.