For the ‘Program Analysis and Transformation’ seminar I compared three language workbenches, namely Jetbrains Meta Programming System (MPS), Spoofax and Actifsource (Although Actifsoure is not a language workbench but rather model driven development tools).
This post is a short overview over the key strengths and weaknesses of these three tools. The more complete analysis with proper introduction of the tools, explanation of how they work and more detailed comparison can be read in my paper here.
- Excellent IDE support for the created languages. When you have built your language you already have a good IDE for it. But you can add more, like refactoring’s, code flow analysis etc.
- You cannot enter code which is not part of your language.
- It’s easy to navigate through code. Even better, you can look up at anytime how a domain specific language is implemented, even for the MPS languages. This way you can learn from existing languages implementations.
- It has module support: This allows you to include existing languages into your project. For example you can include the MPS ‘Java’-language. Later on you can include extension to that language, like closures etc. Or extend it yourself.
- MPS is not text based and your code is not stored in text files. This creates a lot of issues. You cannot use text tools like text-editors, diff-tools, etc. Event worse, you cannot copy and paste code around etc. You need to go through extra steps to talk to external libraries and system.
- MPS is a standalone tool. It’s not an Eclipse or IntelliJ plug-in. Therefore you cannot use and mix it with other tools.
- Everything is text bases, no special files. It uses a classical approach with grammar definition and transformation rules to implement domain specific languages.
- The same transformation language is used for different purposes, like translating the domain specific language to the target platforms, for code completion, for reference lookups, error detection etc.
- Spoofax is an Eclipse plug-in. And you can export your domain specific language with the IDE support as Eclipse plug-in.
- For advances IDE features like refactoring you have to fall back to the Eclipse API’s. Spoofax doesn’t have direct support for such things.
- The IDE support for its own languages is quite disappointing. This also includes the navigation through the code.
Note that Actifsoure is not a language workbench, therefore it’s not really comparable to the other two tools.
- Much easier to learn than the other two tools. Mainly because it only allows UML to model your programs.
- You can only enter elements which are part of your UML-dialect.
- It runs on Eclipse, so you can use and combine it with other tools.
- It only supports UML as modeling language.
- The models are not text based. Again you cannot use you’re text based tools like diff-tools on it.
More more more…
Read my paper for a more complete comparison. Christopher Guntli also analyzed two other language workbenches Xtext and EMFText. You can find his paper here. All the publications of the seminar can be found here.
Take a look at the comments for some clarifications about Actifsource and MPS:
- Being Erica