Completed ad-hoc lexer and parser.