Day 2 -

June 6th

Track 2 (Waterlink Atrium)

12:00 - 12:45

Teaching Domain Specific Languages in Scala

In 2017, I was asked to teach a small, 3 credits master course on engineering domain specific languages. At the time I was already a Scala enthusiast, and I had no doubt that it would have been the best language to teach this course. While learning about DSL, students are introduced to the basics like functional domain modeling, parser combinators, extension and symbolic-named methods, but also advanced topics like metaprogramming, and how to implement programming language features in Visual Studio Code (using Scala.js).

After a brief introduction on DSLs and the context where I teach them, the talk will focus on two main areas:

  • Why Scala is suitable for internal and external DSL development, i.e., what are the characteristics of the language, the platforms, and the libraries in the community that make it amazing to teach (and engineer) DSLs.
  • How to structure a course and what are the possible topics and areas to cover, including how to design compelling assignments where students build software inspired by real DSLs.

The talk will include examples of what the best students were able to achieve. Furthermore, I will pinpoint controversial aspects concerning the actual state of the language, libraries, and tools that are connected to DSL development, and debunk a few misconceptions around DSLs that made them a little unpopular in the Scala world.

Andrea Mocci

Scala Center

I am currently a Junior Group Leader at CodeLounge, a R&D group headed by Dr. Marco D’Ambros and Prof. Dr. Michele Lanza. My main responsibilities include being the tech lead for CodeLounge’s team and projects, and a lot of actual development, mostly on the backend side, including as well machine learning, natural language processing.

I am passionate about functional programming in many flavors, e.g. languages like Scala and reactive technologies like Akka. Apart from R&D, I do a lot of teaching. I have been the lead developer of Tako, an extension for Visual Studio Code that records many aspects of your programming activity and provides a digest to allow some self-reflection on what you have done, how you spent your time, and which entities you worked on.

In the past, I’ve been a postdoctoral researcher at USI Lugano, and at MIT. I got my B.Sc., M.Sc. and PhD at Politecnico di Milano, where I have been advised by Prof. Carlo Ghezzi.

Subscribe

Join our conference

Subscribe and follow @ScalaDays on Twitter for the latest conference updates.