Optimal Language Design is Hard: A Case Study in ECMAScript (JavaScript) Standardization
In addition to requirements of a purely technical nature, the evolution of widely adopted programming languages is oftentimes steered by preferences of individual members—either persons or organizations—of the language maintenance team, who may associate issues to particular design aspects. For instance, when adding a new primitive data type to a language, language designers may suggest alternative semantics for equality to existing data types, as well as explicitly specify issues they wish to avoid (such as inconsistent behavior across number-like types). The decision-making process can span over multiple years and can be highly unstructured and, in a dynamic and distributed language design team, the cumulated understanding of previously discussed design alternatives can be thus lost over time.
In this paper, we present a domain-specific language to specify a certain kind of language evolution proposals—where the design space can be presented as a collection of interconnected individual design points. With each design point, one can associate a set of issues it could raise that should be avoided. From a DSL specification, an interactive web-based tool is generated that allows exploring the design space of a proposal.
Further assigning weights to issues, we formulate an optimization problem where the goal is to select alternatives for individual design aspects to minimize the total weight of occurring issues. We prove that this optimization problem is NP-hard. We reduce this problem to an integer linear programming problem, and incorporate a solver into our interactive tool. We demonstrate the feasibility of our approach by using our DSL to specify the ECMAScript proposal Records & Tuples, and demonstrate that any design choice—as described in the proposal—will necessarily raise issues.
Thu 12 JunDisplayed time zone: Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna change
13:30 - 15:00 | SLE Session 2: Language and Framework DesignSLE 2025 at M 001 Chair(s): Elizabeth Scott Royal Holloway University of London | ||
13:30 22mTalk | A Model-Driven Approach to Design, Generation, and Deployment of GUI Component Libraries SLE 2025 Arkadii Gerasimov RWTH Aachen University, Nico Jansen Software Engineering, RWTH Aachen University, Judith Michael University of Regensburg, Bernhard Rumpe RWTH Aachen University, Sebastian Will RWTH Aachen | ||
13:52 22mTalk | TranspileJS, an Intelligent Framework for Transpiling JavaScript to WebAssembly SLE 2025 José Pedro Ferreira University of Porto, Portugal, João Bispo Faculdade de Engenharia e Universidade do Porto, Susana Lima | ||
14:15 22mTalk | Optimal Language Design is Hard: A Case Study in ECMAScript (JavaScript) Standardization SLE 2025 Philipp Riemer Leipzig University, Yury Nikulin University of Turku, Ashley Claymore , Mikhail Barash University of Bergen | ||
14:37 22mTalk | AnyText: Incremental, left-recursive Parsing and Pretty-Printing from a single Grammar Definition with first-class LSP support SLE 2025 Georg Hinkel RheinMain University of Applied Sciences, Wiesbaden, Germany, Alexander Hert RheinMain University of Applied Sciences, Wiesbaden, Germany, Niklas Hettler RheinMain University of Applied Sciences, Wiesbaden, Germany, Kevin Weinert RheinMain University of Applied Sciences, Wiesbaden, Germany |