Welcome to MSDN Blogs Sign in | Join | Help

Composing DSLs in our tools

Susan says1. Composing languages: a DSL can also be categorized based on whether it an encapsulated DSL that represents an application domain (e.g. finance, medical, etc) or an aspectual DSL that represents a concern that cuts across the application (concurrency, exception management, etc). Aspectual DSL are more difficult to compose and integrate as they influence the semantics of the other DSL. What type of support is currently provided or planned for aspectual DSL with MS DSL tool?

Thanks for the question, Susan.

There are a couple of interesting ways to tackle aspects like this. One is to compile to AOP, which I don't think we'll be doing. Another is to create cascading templates, which you will be able to do in the version of DSL Tools that will be out in a few weeks. Here's the way it works:

  • Template-1 reads DSL-A and -- instead of producing a finished artefact -- produces ...
  • Template-2, which reads DSL-B and produces (either Template-3... or) a finished artefact (program code, configuration files, etc).

This will be easier to do in the next release due out soon. I've put a note in my diary to blog the How To details then.

Published Wednesday, May 04, 2005 4:40 PM by Alan Cameron Wills

Comments

# re: Composing DSLs in our tools

Not to restate the obvious, but Daisy-Chaining or Pipelining is still a very powerful and useful mechanism. Not only can you do as Alan says (eg, feed the output of your DSL #1 into your own DSL #2) but this also allows you build an alternate 'front end' for the input for 3rd party or legacy apps in a way that would otherwise be very error prone, tedious, cumbersome, or down right confusing to get right. One example of this concept is how the VS Team System App Designer, SD & LDD together provide a graphical front end that ultimately feeds the VS project system, code model, and the SDM compiler.
Saturday, May 07, 2005 1:32 AM by SteveAn

# re: Composing DSLs in our tools

I'm curious as to how the "cascading template" approach would be different to the MDA approach of incremental model refinement through model transformation?
Sunday, May 08, 2005 3:37 PM by Murray Spork

# Alan Cameron Wills Domain Specific Languages Composing DSLs in our | debt consolidator

New Comments to this post are disabled
 
Page view tracker