Google Research

On the design of the ECMAScript Reflection API

TOPLAS (Transactions on Programming Languages and Systems) (2012)

Abstract

We describe in detail the new reflection API of the upcoming Javascript standard. The most prominent feature of this new API is its support for creating proxies: virtual objects that behave as regular objects, but whose entire “meta-object protocol” is implemented in Javascript itself. Next to a detailed description of the API, we describe a more general set of design principles that helped steer the API’s design, and which should be applicable to similar APIs for other languages. We also describe access control abstractions implemented in the new API, and provide an operational semantics of an extension of the untyped lambda-calculus featuring proxies.

Research Areas

Learn more about how we do research

We maintain a portfolio of research projects, providing individuals and teams the freedom to emphasize specific types of work