Results 1 -
1 of
1
Implementing continuation marks in JavaScript
- Proceedings of the 2008 ACM SIGPLAN Workshop on Scheme and Functional Programming
, 2008
"... MzScheme’s continuation marks provide a flexible mechanism for implementing a number of useful language features and tools. We demonstrate the simplicity and utility of continuation marks by adapting them for JavaScript as frame-based stack marks using the Rhino implementation, showing a simple mode ..."
Abstract
-
Cited by 3 (0 self)
- Add to MetaCart
MzScheme’s continuation marks provide a flexible mechanism for implementing a number of useful language features and tools. We demonstrate the simplicity and utility of continuation marks by adapting them for JavaScript as frame-based stack marks using the Rhino implementation, showing a simple model of their behavior, and using them to build a toy debugger. Along the way, we discover a few interesting things. First, it requires some thinking—but not much code—to add continuation marks to JavaScript. Second, coupling tail-calling with the “return” of statement-based languages leads to some interesting problems in formulating a semantics. Third, building a debugger based on continuation marks highlights (by its absence) the elegance of Scheme’s simple syntax and hygienic macro system. 1.

