How to define a grammar (context-free) for a new programming language (imperative programming language) that you want to design from scratch.
In other words: How do you
Have a look at Bison, maybe that's what you are looking for?