The Essence of JavaScript

Arjun Guha, Claudiu Saftoiu, Shriram Krishnamurthi. The Essence of JavaScript. In Theo D Hondt, editor, ECOOP 2010 - Object-Oriented Programming, 24th European Conference, Maribor, Slovenia, June 21-25, 2010. Proceedings. Volume 6183 of Lecture Notes in Computer Science, pages 126-150, Springer, 2010. [doi]

Abstract

We reduce JavaScript to a core calculus structured as a small-step operational semantics. We present several peculiarities of the language and show that our calculus models them. We explicate the desugaring process that turns JavaScript programs into ones in the core. We demonstrate faithfulness to JavaScript using real-world test suites. Finally, we illustrate utility by defining a security property, implementing it as a type system on the core, and extending it to the full language.