Today we are going to talk about a concept known as “domain-specific languages”, and in particular “embedded domain-specific languages”. It may sound like a jargony term, but it’s something that you have definitely come across and you may even use it on a daily basis.
After giving the upfront definitions so that we all understand what a domain-specific language is, we will create one right in Swift and progressively add more and more advanced features to it. It’s a toy example, but it contains a lot of the core ideas and it can be a lot of fun to play with.