Speaker Deck

Parsing, Compiling, and Static Metaprogramming

by Patrick Dubroy

Published September 13, 2013 in Technology

Learn how to use compilers and parser generators to remove boilerplate, build DSLs, and generally do the impossible.

I’ll explain the basics of how compilers work, and give an overview of some popular JS tools & libraries. I’ll demonstrate how they can help you do all kinds of useful things, like:

- presubmit checks for style guide violations
- extracting strings requiring translation in your code
- automatically inserting logging statements around certain function calls

Finally, for the budding language designers, I’ll explain how to create your own compiled-to-JS language in five minutes using a parser generator.