Researchers at the MIT CSAIL have just launched a new tool, BuildIt, designed to make it easier for developers to create their own programming languages.

According to MIT CSAIL, many programming languages are classified as domain-specific languages (DSLs), which are languages that have been adapted in some way from traditional languages and designed for use by non-programmers. 

One issue with DSLs, however, is that they can be difficult to create. For example, if one wants to create a new DSL from C++, they’d need to hire an expert to design it by looking at programs the team has already written to determine what elements need to be incorporated, and they would also need to write a new compiler, parser, and code generator, the team explained.

BuildIt aims to eliminate the need to hire an expert. It acts as a multi-staging framework to reduce the complexity of a language down to a set of a few common features.  Developers will be able to use BuildIt to create DSLs just from taking their existing programs and making a few changes. 

“BuildIt doesn’t have a full view of the program, instead examining it through the narrow window of individual simple operations happening in the program, like multiplication and division,” said Ajay Brahmakshatriya, PhD student at MIT CSAIL who co-wrote a new paper on the system with MIT professor Saman Amarasinghe. “It’s the equivalent of a person walking through a maze: even if they can only see one part of it at a time, they can navigate it by recording their observations and leaving markers on different paths they’ve explored.” 

Amarasinghe also noted that he hopes BuildIt will inspire non-programmers to use programming in their work since they can use these DSLs without much programming knowledge.

“With BuildIt, anybody with the knowledge of the application domain, from a physics researcher to a vaccine developer, can write their own DSL instead of creating a large library,” he said. “That opens up a lot of exciting possibilities in terms of pushing forward new innovations in the coming years.”