Extensible programming languages are the next big thing. Decades of work on programming-language design have given us powerful abstractions that cover a large problem space, but no one abstraction can close the gap between a programming language and all programming problems. When a programming language is extensible, a programmer can afford to create the right abstraction to solve each problem.
Racket’s Lisp and Scheme heritage gives it a head start on language extensibility, but Scheme’s macro system turned out to be a starting point instead of a conclusion. The practice of building Racket and building applications has drawn us continually back the problem of building languages and composable language extensions.
We have been able to grow the idea of macros to the more expressive and convenient facilities that are found in Racket today. Key elements include a novel model of scope, a module system that enforces a phase separation, submodules that generalize program phases, and improved pattern-parsing and error-reporting libraries. These elements take on a specific flavor in our macro setting, but each element also reflects a general problem and points to a fundamental solution that designers of extensible languages can embrace.
Matthew Flatt is a professor in the School of Computing at the University of Utah, where he works on extensible programming languages, runtime systems, and applications of functional programming. He is one of the developers of the Racket programming language. He received his PhD from Rice University in 1999.