initial part of syntax construction

* remove comments and empty lines
* join non-terminating lines
* extract literals