Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Choice of DSL framework

Tags:

.net

dsl

I am working on a project that requires me to define a DSL. Since coming up with the right DSL is critical for my project, I decided to evaluate existing frameworks that help in defining DSLs,parsing it and code generation(which has to be in a .NET based language) The frameworks I considered are :

  1. Boo language that has a customizable compiler and pythonish syntax ideal for defining a DSL.
  2. Windows powershell that supports extensible commandlets.
  3. Microsoft DSL tools that support visual modeling,but less flexible(in my opinion)
  4. ANTLR which is proven tool
  5. C# fluent interfaces.(Not so happy with this)
  6. Oslo framework (Is it mature to be used in production?)

There are pros and cons of each of the framework mentioned above and I am unable to make a decision.Given a choice between the above frameworks, which one would you choose and why?

Is there any other framework so fundamental that I might have missed out?

Any help or guidance would be greatly appreciated.

like image 979
Prashanth Avatar asked May 21 '09 08:05

Prashanth


3 Answers

Xtext: http://www.eclipse.org/Xtext/

like image 187
Dominik Avatar answered Sep 22 '22 03:09

Dominik


In a question of mine that touched the subject of DSL's, it was suggested to me to use a combination of Irony and DLR. I don't know stable they are however. Irony is an Alpha, and DLR, although stable, is still in v0.9. I'm aiming to start using Irony myself in a week or two, so then I will be able to provide some feedback. On the bright side however - they are both opensource, so you can fix bugs yourself.

like image 40
Vilx- Avatar answered Sep 23 '22 03:09

Vilx-


If you are planning to implement an external DSLs , Spoofax ( http://strategoxt.org/Spoofax )is a nice Language Workbench to do this. It is a parser-based textual Langauge Workbench that leverage several state-of-art technology such as SDF , Stratego. Besides the DSL implemenation , you could get a very rich editor services such as, code completion , outline view , intellisense etc.

It comes with a nice sample DSL implementation and code generation to Java. It might also work as a starting point to get started with the tools.

Following tutorial details about the usage this langauge workbench : http://strategoxt.org/Spoofax/Tour .

Hope it helps!

Edit -1 :

Following is an example of a language implemented using this Langauge Workbench : http://mobl-lang.org/.

like image 35
Adil Akhter Avatar answered Sep 20 '22 03:09

Adil Akhter