EBNF grammar, lexer and parser for the Cool programming language.
The full language grammar is described in cool.tm using the EBNF-like format specified by TextMapper.
Firstly we need to make sure the TextMapper tool is available:
$ go get github.com/inspirer/textmapper/tm-go/cmd/textmapper
Then, we can regenerate all the go
code for both the lexer and parser:
$ git clone https://github.com/nazavode/cool.git
$ cd cool
$ make