Have you ever found yourself wondering, “Hmm, what should I procrastinate with next?”
Luckily for you, Tim Nugent, Jon Manning, and Paris Buttfield-Addison have the answer: build your own programming language! They know what you’re thinking, "Hang on, there. Isn’t that the domain of all those clever boffins hanging out over in Clever Boffinlandia? I’m just a developer.”
But luckily again—wow, you really are lucky today—those same clever boffins have made it easier to make your own programming languages. There are a bunch of reasons why you’d want to make your own language:
Being able to build your own programming language is another tool in you tool belt, and who doesn’t love having a nice heavy tool belt?
“Okay, you’ve convinced me. What do we do?”
Really? Sweet. Well, Tim, Jon, and Paris build their very own programming language from nothing to having a working interpreter using ANTLR. They discuss their programming language design and why and how to implement it in ANTLR’s grammar. They’ll use ANTLR to generate a parser when the grammar is complete and implement their interpreter. They’ll be building their language in JS, but if you’re feeling adventurous, you can use any of the languages ANTLR supports.
You’ll be able to see them take their new language out for a spin, and, if there’s time, take a look at some other options for building languages, such as using PEGs, and some other steps you can take to improve their new language. You’ll leave ready to create your own programming languages and solve new and interesting problems using your newly acquired status as a clever boffin.
Tim Nugent pretends to be a mobile app developer, game designer, tools builder, researcher, and tech author. When he isn’t busy avoiding being found out as a fraud, Tim spends most of his time designing and creating little apps and games he won’t let anyone see. He also spent a disproportionately long time writing his tiny little bio, most of which was taken up trying to stick a witty sci-fi reference in…before he simply gave up. He’s currently writing Practical Artificial Intelligence with Swift for O’Reilly and building a game for a power transmission company about a naughty quoll (a quoll is an Australian animal).
Jon Manning is the cofounder of independent game development studio Secret Lab. He’s working on the critically acclaimed award-winning adventure game Night in the Woods, which includes his interactive dialogue system Yarn Spinner. He’s written a whole bunch of books for O’Reilly about iOS development and game development. Jon holds a PhD about jerks on the internet.
Paris Buttfield-Addison is a cofounder of Secret Lab, a game development studio based in beautiful Hobart, Australia. Secret Lab builds games and game development tools, including the multi-award-winning ABC Play School iPad games, the BAFTA- and IGF-winning Night in the Woods, the Qantas airlines Joey Playbox games, and the Yarn Spinner narrative game framework. Previously, Paris was a mobile product manager for Meebo (acquired by Google). Paris particularly enjoys game design, statistics, blockchain, machine learning, and human-centered technology research and writes technical books on mobile and game development (more than 20 so far) for O’Reilly and is currently writing Practical AI with Swift and Head First Swift. He holds a degree in medieval history and a PhD in computing.
©2019, O'Reilly Media, Inc. • (800) 889-8969 or (707) 827-7019 • Monday-Friday 7:30am-5pm PT • All trademarks and registered trademarks appearing on oreilly.com are the property of their respective owners. • email@example.com